Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mark & pointers to Freeze objects as llvm.invariant #6351

Closed
thestinger opened this issue May 9, 2013 · 1 comment
Closed

mark & pointers to Freeze objects as llvm.invariant #6351

thestinger opened this issue May 9, 2013 · 1 comment
Labels
A-codegen Area: Code generation I-slow Issue: Problems and improvements with respect to performance of generated code.

Comments

@thestinger
Copy link
Contributor

Const objects are immutable or can be statically frozen, so this is a safe optimization for all safe code and correct unsafe code. However, there may objects violating the mutability rules with unsafe and requiring #[mutable].

@thestinger
Copy link
Contributor Author

This isn't the best way to communicate this information.

flip1995 pushed a commit to flip1995/rust that referenced this issue Nov 20, 2020
Rustup

r? `@ghost`

changelog: none
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-codegen Area: Code generation I-slow Issue: Problems and improvements with respect to performance of generated code.
Projects
None yet
Development

No branches or pull requests

1 participant