We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This bug seems to only trigger on Windows (possibly only when built with MSVC).
The following example will reproduce the bug (compile with --emit-llvm, removing pretty much anything makes the bug disappear):
--emit-llvm
#[import(cc = "thorin")] fn cuda(_dev: i32, _grid: (i32, i32, i32), _block: (i32, i32, i32), _body: fn() -> ()) -> (); enum needs_to_be_here_to_trigger_the_bug { A, B, C, D // any fewer members will not trigger the bug } fn @no_bug_without_me_either(need: needs_to_be_here_to_trigger_the_bug) -> u32 { match need { needs_to_be_here_to_trigger_the_bug::A => 1, needs_to_be_here_to_trigger_the_bug::B => 2, needs_to_be_here_to_trigger_the_bug::C => 3, needs_to_be_here_to_trigger_the_bug::D => 4, } } struct G { xxx: fn(fn(C) -> ()) -> fn() -> (), } struct C { } fn @invoke(body: fn(C) -> ()) -> () { @body(C {}) } fn @launch(device: i32, body: fn(G) -> ()) -> () { cuda(device, (1, 1, 1), (1, 1, 1), @|| @body(G { xxx = @|body| @|| invoke(body), })) } struct Device { launch: fn(fn(G) -> ()) -> (), } fn @createDevice(device: i32) { Device { launch = @|body| launch(device, body) } } #[export] fn benchmark_print_info(device: i32) { createDevice(device); 0 } #[export] fn benchmark_run(device: i32, argc: i32, argv: &mut u8) { createDevice(device); }
results in
Assertion failed: cont_scope.has_free_params(), file src\thorin\analyses\scope.cpp, line 93
The text was updated successfully, but these errors were encountered:
Can you provide a commit hash?
Sorry, something went wrong.
thorin: fb0f721 artic: 0f50091011f2bf82efd460264f2f40781a85f72b runtime: 5c1a78c07cbeaea16fd61c73e92fd7112dd62ab7
No branches or pull requests
This bug seems to only trigger on Windows (possibly only when built with MSVC).
The following example will reproduce the bug (compile with
--emit-llvm
, removing pretty much anything makes the bug disappear):results in
The text was updated successfully, but these errors were encountered: