You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to use the documented built-in add_with_carry like in the snippet below:
import float32;
import std;
pub fn double_fraction_carry(f: float32::F32) -> (uN[float32::F32_FRACTION_SZ], u1) {
let f = f.fraction as uN[u32:23 + u32:1];
let (c, f_x2) = add_with_carry(f, f);
(f_x2[0+:u23], c)
}
ir_converter_main fails with the following error:
xls_work_dir/user_module.x:8:35-8:41
0006: pub fn double_fraction_carry(f: float32::F32) -> (uN[float32::F32_FRACTION_SZ], u1) {
0007: let f = f.fraction as uN[u32:23 + u32:1];
0008: let (c, f_x2) = add_with_carry(f, f);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^----^ IrConversionError: Could not find name for invocation: `add_with_carry`; available: [double_fraction_carry]
0009: (f_x2[0+:u23], c)
0010: }
The text was updated successfully, but these errors were encountered:
If we're not going to add an IR node for it (and I don't think we have any active plans to) I think we should probably remove this in favor of stdlib userspace helper function.
cdleary
added
the
dslx
DSLX (domain specific language) implementation / front-end
label
Jun 15, 2024
Describe the bug
When trying to use the documented built-in
add_with_carry
like in the snippet below:ir_converter_main
fails with the following error:The text was updated successfully, but these errors were encountered: