-
Notifications
You must be signed in to change notification settings - Fork 159
Closed
Labels
IR differenceA difference in ClangIR-generated LLVM IR that could complicate reusing original CodeGen testsA difference in ClangIR-generated LLVM IR that could complicate reusing original CodeGen tests
Description
When looking at some C generated code I noticed that most cir.cmp
operations that were generated were of type s32i
, and then immediately converted to bool before used in if statements etc.
I found the root cause in CIRGenScalarExpr, will publish a fix over the coming week that simplifies the generated code for most cases.
———
I will note that a lot of tests rely on 1:1 generated CIR/LLVMIR, even without using file check variables, which makes such changes a lot harder than they could have been! For example, tests of lowering of complicated scopes and control flow should not check for the way that conditions are evaluated.
bcardosolopes
Metadata
Metadata
Assignees
Labels
IR differenceA difference in ClangIR-generated LLVM IR that could complicate reusing original CodeGen testsA difference in ClangIR-generated LLVM IR that could complicate reusing original CodeGen tests