---
id: 1786
title: "Part 2: Improving crypto code in Rust using LLVM’s optnone"
source_domain: blog.trailofbits.com
source_url: "https://blog.trailofbits.com/2022/02/01/part-2-rusty-crypto/"
published_at: "2022-02-01T12:00:25Z"
tags: ["rust", "cryptography", "llvm", "compilers", "constant-time", "side-channels"]
phying_url: "https://phying.com/item/1786"
lang: en
---

# Part 2: Improving crypto code in Rust using LLVM’s optnone

## Summary

This post implements an optnone attribute in rustc so developers can disable optimizations for security-critical functions, examining the resulting LLVM IR and codegen pitfalls.

## Intelligence Metadata

- **Sources:** blog.trailofbits.com
- **Published:** 2022-02-01T12:00:25Z
- **Original:** https://blog.trailofbits.com/2022/02/01/part-2-rusty-crypto/
- **Phying News:** https://phying.com/item/1786
