Skip to content

dialects: (llvm) add CondBr#5710

Open
sueszli wants to merge 1 commit intoxdslproject:mainfrom
sueszli:llvm.cond_br
Open

dialects: (llvm) add CondBr#5710
sueszli wants to merge 1 commit intoxdslproject:mainfrom
sueszli:llvm.cond_br

Conversation

@sueszli
Copy link
Contributor

@sueszli sueszli commented Mar 7, 2026

No description provided.

@codecov
Copy link

codecov bot commented Mar 7, 2026

Codecov Report

❌ Patch coverage is 98.14815% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 86.35%. Comparing base (61608e7) to head (53d9acb).

Files with missing lines Patch % Lines
xdsl/backend/llvm/convert.py 95.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5710   +/-   ##
=======================================
  Coverage   86.34%   86.35%           
=======================================
  Files         406      406           
  Lines       57753    57796   +43     
  Branches     6709     6720   +11     
=======================================
+ Hits        49869    49909   +40     
- Misses       6325     6326    +1     
- Partials     1559     1561    +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment on lines +586 to 589
// CHECK: define i32 @"cond_br_op"(i1 %".1", i32 %".2", i32 %".3")
// CHECK: br i1 %".1", label %{{.*}}, label %{{.*}}
// CHECK: ret i32

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not check for the whole function?

Comment on lines +50 to +52
// CHECK: llvm.cond_br %cond_br_cond, ^bb1(%cond_br_arg : i32), ^bb2(%cond_br_arg : i32)
// CHECK: ^bb1(%cond_br_then : i32):
// CHECK: ^bb2(%cond_br_else : i32):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not check whole thing here?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and below

if block.args:
builder = ir.IRBuilder(block_map[block])
for arg in block.args:
phi = builder.phi(convert_type(arg.type))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this seems weird, are these ops modified later? worth a comment IMO where in the code the arguments will be provided

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants