about summary refs log tree commit diff
path: root/src/librustc_codegen_llvm/declare.rs
AgeCommit message (Collapse)AuthorLines
2020-08-30mv compiler to compiler/mark-95/+0
2020-08-06Incorporate tracing cratebishtpawan-1/+1
2020-03-30rustc -> rustc_middle part 3 (rustfmt)Mazdak Farrokhzad-1/+1
2020-03-30rustc -> rustc_middle part 2Mazdak Farrokhzad-1/+1
2020-03-11librustc_codegen_llvm: Replace deprecated API usageTomasz Miąsko-1/+1
2020-03-11librustc_codegen_llvm: Use slices instead of 0-terminated stringsTomasz Miąsko-5/+4
Changed functions: * LLVMRustGetOrInsertFunction * LLVMRustGetNamedValue * LLVMRustBuildCall (removed unused name argument) * LLVMRustInlineAsm * LLVMRustInlineAsmVerify * LLVMRustAppendModuleInlineAsm
2020-02-05Selectively disable sanitizer instrumentationTomasz Miąsko-16/+0
Add `no_sanitize` attribute that allows to opt out from sanitizer instrumentation in an annotated function.
2019-12-22Format the worldMark Rousskov-48/+19
2019-12-11rustc: Link LLVM directly into rustc againAlex Crichton-0/+1
This commit builds on #65501 continue to simplify the build system and compiler now that we no longer have multiple LLVM backends to ship by default. Here this switches the compiler back to what it once was long long ago, which is linking LLVM directly to the compiler rather than dynamically loading it at runtime. The `codegen-backends` directory of the sysroot no longer exists and all relevant support in the build system is removed. Note that `rustc` still supports a dynamically loaded codegen backend as it did previously, it just no longer supports dynamically loaded codegen backends in its own sysroot. Additionally as part of this the `librustc_codegen_llvm` crate now once again explicitly depends on all of its crates instead of implicitly loading them through the sysroot. This involved filling out its `Cargo.toml` and deleting all the now-unnecessary `extern crate` annotations in the header of the crate. (this in turn required adding a number of imports for names of macros too). The end results of this change are: * Rustbuild's build process for the compiler as all the "oh don't forget the codegen backend" checks can be easily removed. * Building `rustc_codegen_llvm` is much simpler since it's simply another compiler crate. * Managing the dependencies of `rustc_codegen_llvm` is much simpler since it's "just another `Cargo.toml` to edit" * The build process should be a smidge faster because there's more parallelism in the main rustc build step rather than splitting `librustc_codegen_llvm` out to its own step. * The compiler is expected to be slightly faster by default because the codegen backend does not need to be dynamically loaded. * Disabling LLVM as part of rustbuild is still supported, supporting multiple codegen backends is still supported, and dynamic loading of a codegen backend is still supported.
2019-12-04Migrate to LLVM{Get,Set}ValueName2Josh Stone-2/+1
The deprecated `LLVM{Get,Set}ValueName` only work with NUL-terminated strings, but the `2` variants use explicit lengths, which fits better with Rust strings and slices. We now use these in new helper functions `llvm::{get,set}_value_name` that convert to/from `&[u8]`.
2019-12-03rustc_codegen_llvm: move NoReturn attribute to apply_attrs_llfn.Eduard-Mihai Burtescu-7/+0
2019-12-03rustc_codegen_ssa: take a FnAbi instead of a FnSig in declare_fn.Eduard-Mihai Burtescu-8/+5
2019-12-03rustc_codegen_ssa: remove define_fn and define_internal_fn.Eduard-Mihai Burtescu-22/+0
2019-11-03rustc_codegen_ssa: rename FnTypeLlvmExt to FnAbiLlvmExt.Eduard-Mihai Burtescu-1/+1
2019-11-03rustc: rename {Fn,Arg}TypeExt to {Fn,Arg}AbiExt.Eduard-Mihai Burtescu-1/+1
2019-11-03rustc_target: rename {Fn,Arg}Type to {Fn,Arg}Abi.Eduard-Mihai Burtescu-4/+4
2019-07-09Pass type to byval attributesNikita Popov-1/+1
2019-05-14removes `AbiMethods`Saleem Jaffer-1/+1
2019-05-14refactor completeSaleem Jaffer-4/+4
2019-05-14some more refactor of FnType. Things build nowSaleem Jaffer-3/+3
2019-02-18librustc_codegen_llvm => 2018Taiki Endo-7/+7
2019-01-25Resolve breakageSimonas Kazlauskas-22/+2
2019-01-24Support revisions for codegen testsSimonas Kazlauskas-2/+2
`compile-flags: -Copt-level` will avoid adding -O. Similarly for -g and -Cdebuglevel.
2019-01-24Implement optimize(size) and optimize(speed)Simonas Kazlauskas-6/+15
2018-12-25Remove licensesMark Rousskov-9/+0
2018-12-12rustc: Switch `extern` functions to abort by default on panicAlex Crichton-10/+1
This was intended to land way back in 1.24, but it was backed out due to breakage which has long since been fixed. An unstable `#[unwind]` attribute can be used to tweak the behavior here, but this is currently simply switching rustc's internal default to abort-by-default if an `extern` function panics, making our codegen sound primarily (as currently you can produce UB with safe code) Closes #52652
2018-11-16[eddyb] rustc_codegen_ssa: rename `interfaces` to `traits`.Eduard-Mihai Burtescu-1/+1
2018-11-16Finished moving backend-agnostic code to rustc_codegen_ssaDenis Merigoux-1/+1
2018-11-16Move doc to trait declarationsDenis Merigoux-40/+0
2018-11-16Adapt code to latest rustc master changesDenis Merigoux-2/+2
2018-11-16Generalized mir::codegen_mir (and all subsequent functions)Denis Merigoux-120/+128
2018-11-16Removed genericity over Value in various functionsDenis Merigoux-9/+9
Prelude to using associated types in traits rather than type parameters
2018-11-16Generalized base.rs#call_memcpy and everything that it usesDenis Merigoux-7/+11
Generalized operand.rs#nontemporal_store and fixed tidy issues Generalized operand.rs#nontemporal_store's implem even more With a BuilderMethod trait implemented by Builder for LLVM Cleaned builder.rs : no more code duplication, no more ValueTrait Full traitification of builder.rs
2018-10-24Make declare_fn accept PolyFnSig instead of Ty.Masaki Hara-11/+7
2018-10-24Make declare_fn aware of vtable shims.Masaki Hara-3/+5
2018-10-11Support for disabling the PLT on ELF targetsGabriel Majeri-0/+2
Disable the PLT where possible to improve performance for indirect calls into shared libraries. This optimization is enabled by default where possible. - Add the `NonLazyBind` attribute to `rustllvm`: This attribute informs LLVM to skip PLT calls in codegen. - Disable PLT unconditionally: Apply the `NonLazyBind` attribute on every function. - Only enable no-plt when full relro is enabled: Ensures we only enable it when we have linker support. - Add `-Z plt` as a compiler option
2018-09-30use is_uninhabited in more placesJorge Aparicio-2/+2
2018-09-29Revert "Auto merge of #53508 - japaric:maybe-uninit, r=RalfJung"Ralf Jung-2/+2
This reverts commit c6e3d7fa3113aaa64602507f39d4627c427742ff, reversing changes made to 4591a245c7eec9f70d668982b1383cd2a6854af5.
2018-09-22use is_uninhabited in more placesJorge Aparicio-2/+2
2018-08-10Introduce SmallCStr and use it where applicable.Michael Woerister-10/+4
2018-07-31Make globals with private linkage unnamed. Fixes #50862.Colin Pronovost-1/+9
2018-07-30rustc_codegen_llvm: fix tidy errors.Irina Popa-1/+6
2018-07-30rustc_codegen_llvm: use safe references for Value.Irina Popa-29/+29
2018-07-30rustc_codegen_llvm: use safe references for Type.Irina Popa-6/+6
2018-05-17Rename trans to codegen everywhere.Irina Popa-0/+223