about summary refs log tree commit diff
path: root/src/test/codegen
AgeCommit message (Collapse)AuthorLines
2020-07-14Stabilize control-flow-guard codegen optionAndrew Paverd-4/+4
2020-07-13Rollup merge of #74285 - wangtheo:issue-71669, r=lcnrManish Goregaokar-0/+91
#71669: add ui, codegen tests for volatile + nearby int intrinsics Added some tests for intrinsics. See https://github.com/rust-lang/rust/issues/71669.
2020-07-13Added ui tests for volatile and nearby intrinsicsTeddy_Wang-0/+18
2020-07-12Added tests for volatile and nearbyint intrinsicsTeddy_Wang-0/+73
2020-07-10Only add cfguard module flag on windows-msvcAndrew Paverd-0/+14
2020-07-09Ignore changes when debug assertions are enabled.Eric Huss-3/+3
2020-07-08Disable 44056 test with debug on macos.Eric Huss-0/+1
2020-07-02Add codegen testsChristopher Serr-0/+331
2020-07-01Ignoring test case: [codegen] repr-transparent-aggregates-1.rs for aarch64joacar01-0/+1
Copyright (c) 2020, Arm Limited.
2020-06-27Rollup merge of #73525 - cuviper:llvm11, r=nikicManish Goregaokar-3/+3
Prepare for LLVM 11 These are just the code changes needed to build with the current LLVM master (version 11). r? @nikic
2020-06-26Rollup merge of #72620 - tmiasko:linkage-name, r=eddybManish Goregaokar-0/+42
Omit DW_AT_linkage_name when it is the same as DW_AT_name The DWARF standard suggests that it might be useful to include `DW_AT_linkage_name` when it is *distinct* from the identifier name. Fixes #46487. Fixes #59422.
2020-06-25Prepare for LLVM 11Josh Stone-3/+3
2020-06-24Split out async fn and generator testTyler Mandry-72/+102
This keeps FileCheck from tripping over unimportant differences in codegen.
2020-06-24Give up on checking filenameTyler Mandry-8/+4
2020-06-24Add generator-debug test for MSVCTyler Mandry-0/+88
..which doesn't use variant types.
2020-06-24Generalize generator-debug test a bitTyler Mandry-21/+19
Don't be so reliant on particular line ordering (though FileCheck makes this hard in general, IMO). Also disable for MSVC.
2020-06-24Add test for generator debuginfoTyler Mandry-0/+94
2020-06-20Auto merge of #73563 - Manishearth:rollup-oowgwwm, r=Manishearthbors-0/+53
Rollup of 9 pull requests Successful merges: - #72456 (Try to suggest dereferences on trait selection failed) - #72788 (Projection bound validation) - #72790 (core/time: Add Duration methods for zero) - #73227 (Allow multiple `asm!` options groups and report an error on duplicate options) - #73287 (lint: normalize projections using opaque types) - #73291 (Pre-compute `LocalDefId` <-> `HirId` mappings and remove `NodeId` <-> `HirId` conversion APIs) - #73378 (Remove use of specialization from librustc_arena) - #73411 (Update bootstrap to rustc 1.45.0-beta.2 (1dc0f6d8e 2020-06-15)) - #73443 (ci: allow gating GHA on everything but macOS) Failed merges: r? @ghost
2020-06-20Add codegen test for multiple `asm!` optionsCamelid-0/+53
2020-06-20Rollup merge of #73404 - ajpaverd:cfguard_syntax, r=Mark-SimulacrumRalf Jung-3/+3
Update CFGuard syntax Update the naming and syntax of the control-flow-guard option, as discussed in #68793. r? @Mark-Simulacrum
2020-06-19Rollup merge of #73054 - RalfJung:dont-panic, r=Mark-SimulacrumRalf Jung-2/+0
memory access sanity checks: abort instead of panic Suggested by @Mark-Simulacrum, this should help reduce the performance impact of these checks.
2020-06-19Rollup merge of #73044 - tmiasko:compiletest-san, r=nikomatsakisRalf Jung-11/+6
compiletest: Add directives to detect sanitizer support Add needs-sanitizer-{address,leak,memory,thread} directive indicating that test requires target with support for specific sanitizer. This is an addition to the existing needs-sanitizer-support directive indicating that test requires a sanitizer runtime library. The existing needs-sanitizer-support directive could be incorporated into the new ones, but I decided to retain it, since it enables running sanitizer codegen tests even when building of sanitizer runtime libraries is disabled.
2020-06-19Rollup merge of #73362 - erikdesjardins:bounds, r=nikomatsakisRalf Jung-0/+44
Test that bounds checks are elided when slice len is checked up-front Closes #69101
2020-06-17ignore-debug: debug assertions in slice indexing prevent the optimizationerikdesjardins-0/+1
2020-06-16we can enable one more codegen test in debug mode nowRalf Jung-2/+0
2020-06-16Update CFGuard syntaxAndrew Paverd-3/+3
2020-06-15elaborate, add check for exact boundsErik Desjardins-1/+18
2020-06-15Update sanitizer testNathan Corbyn-1/+2
2020-06-15Fix sanitizer testNathan Corbyn-2/+1
2020-06-15Fix whitespaceNathan Corbyn-1/+1
2020-06-15Fix exports with `#[inline(always)]`Nathan Corbyn-8/+63
2020-06-15Fix whitespaceNathan Corbyn-1/+1
2020-06-15Export all fns with extern indicatorNathan Corbyn-26/+61
2020-06-15Export `#[inline] #[no_mangle]` fns in cdylibs and staticlibsNathan Corbyn-0/+26
2020-06-15Test that bounds checks are elided when slice len is checked up-frontErik Desjardins-0/+26
2020-06-13compiletest: Add directives to detect sanitizer supportTomasz Miąsko-11/+6
Add needs-sanitizer-{address,leak,memory,thread} directive indicating that test requires target with support for specific sanitizer. This is an addition to the existing needs-sanitizer-support directive indicating that test requires a sanitizer runtime library.
2020-06-07Rollup merge of #72977 - tblah:riscv-codegen-llvm10, r=nikomatsakisDylan DPC-41/+93
Fix codegen tests for RISC-V Some codegen tests didn't seem relevant (e.g. unsupported annotations). The RISC-V abi tests were broken by LLVM 10, c872dcf fixes that (cc: @msizanoen1) I'm not sure about skipping catch-unwind.rs and included that change here mostly as a request for comment - I can't tell if that's a bug.
2020-06-04Revert "Defer creating drop trees in MIR lowering until leaving that scope"Felix S. Klock II-3/+3
This reverts commit 611988551fba1bcbb33ae2e1e0171cb8d2e70d5a.
2020-06-04test: codegen: skip catch-unwind on riscv64Tom Eccles-0/+9
It isn't clear to me if this is a bug or not, hence the FIXME
2020-06-04test: codegen: Add riscv abi llvm intrinsics testTom Eccles-0/+32
2020-06-04test: codegen: riscv64-abi: print value numbers for unnamed func argsTom Eccles-41/+41
LLVM 10 includes a009a60a917bc30940422bcef73f8270566d78db which will print value numbers for unnamed func args. Update these tests to be in line with the referenced clang tests.
2020-06-04test: codegen: skip tests inappropriate for riscv64Tom Eccles-0/+11
2020-05-27Omit DW_AT_linkage_name when it is the same as DW_AT_nameTomasz Miąsko-0/+42
The DWARF standard suggests that it might be useful to include `DW_AT_linkage_name` when it is *distinct* from the identifier name.
2020-05-24Added a codegen test for a recent optimization for overflow-checks=onAlex Gaynor-0/+26
Closes #58692
2020-05-21Auto merge of #71718 - NeoRaider:ffi_const_pure, r=Amanieubors-0/+24
Experimentally add `ffi_const` and `ffi_pure` extern fn attributes Add FFI function attributes corresponding to clang/gcc/... `const` and `pure`. Rebased version of #58327 by @gnzlbg with the following changes: - Switched back from the `c_ffi_const` and `c_ffi_pure` naming to `ffi_const` and `ffi_pure`, as I agree with https://github.com/rust-lang/rust/pull/58327#issuecomment-462718772 and this nicely aligns with `ffi_returns_twice` - (Hopefully) took care of all of @hanna-kruppe's change requests in the original PR r? @hanna-kruppe
2020-05-21Auto merge of #72205 - ecstatic-morse:nrvo, r=oli-obkbors-2/+19
Dumb NRVO This is a very simple version of an NRVO pass, which scans backwards from the `return` terminator to see if there is an an assignment like `_0 = _1`. If a basic block with two or more predecessors is encountered during this scan without first seeing an assignment to the return place, we bail out. This avoids running a full "reaching definitions" dataflow analysis. I wanted to see how much `rustc` would benefit from even a very limited version of this optimization. We should be able to use this as a point of comparison for more advanced versions that are based on live ranges. r? @ghost
2020-05-20Rollup merge of #72139 - nnethercote:standalone-fold, r=cuviperDylan DPC-24/+0
Make `fold` standalone. `fold` is currently implemented via `try_fold`, but implementing it directly results in slightly less LLVM IR being generated, speeding up compilation of some benchmarks. r? @cuviper
2020-05-20Add tests for `#[ffi_const]` and `#[ffi_pure]` function attributesMatthias Schiffer-0/+24
Based on the work of gnzlbg <gonzalobg88@gmail.com>.
2020-05-18Add tests for asm!Amanieu d'Antras-0/+96
2020-05-18Make `fold` standalone.Nicholas Nethercote-24/+0
`fold` is currently implemented via `try_fold`, but implementing it directly results in slightly less LLVM IR being generated, speeding up compilation of some benchmarks. (And likewise for `rfold`.) The commit adds `fold` implementations to all the iterators that lack one but do have a `try_fold` implementation. Most of these just call the `try_fold` implementation directly.