-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Improve ClangCL support by disabling, fixing warnings #5876
New issue
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
Changes from 8 commits
5aad444
a7d4e8c
014afc3
cf946dd
41e8bf8
f7ddd48
4265af5
b19a7b3
3a60c98
b502cae
808c1e7
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -571,7 +571,7 @@ class LowerWarpShuffles : public IRMutator { | |
|
||
Expr wild = Variable::make(Int(32), "*"); | ||
vector<Expr> result; | ||
int bits; | ||
int bits = 0; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The reason this isn't needed is extremely subtle: the function There's no downside to this (this is not performance-critical) and disabling uninitialized use warnings seems significantly worse. |
||
|
||
// Move this_lane as far left as possible in the expression to | ||
// reduce the number of cases to check below. | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -102,9 +102,8 @@ std::string get_env_variable(char const *env_var_name) { | |
if (lvl) { | ||
return std::string(lvl); | ||
} | ||
#endif | ||
|
||
return ""; | ||
#endif | ||
} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This emits an unreachable code warning. |
||
|
||
string running_program_name() { | ||
|
@@ -529,7 +528,7 @@ struct TickStackEntry { | |
int line; | ||
}; | ||
|
||
vector<TickStackEntry> tick_stack; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Throws a warning about missing extern and that it should be static if module-local, which it is. No need to export this. |
||
static vector<TickStackEntry> tick_stack; | ||
|
||
void halide_tic_impl(const char *file, int line) { | ||
string f = file; | ||
|
@@ -609,7 +608,7 @@ void WINAPI generic_fiber_entry_point(LPVOID argument) { | |
|
||
void run_with_large_stack(const std::function<void()> &action) { | ||
#if _WIN32 | ||
constexpr SIZE_T required_stack = 8 * 1024 * 1024; | ||
constexpr auto required_stack = 8 * 1024 * 1024; | ||
|
||
// Only exists for its address, which is used to compute remaining stack space. | ||
ULONG_PTR approx_stack_pos; | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1672,4 +1672,4 @@ Stmt vectorize_loops(const Stmt &stmt, const map<string, Function> &env, const T | |
} | ||
|
||
} // namespace Internal | ||
} // namespace Halide | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This was the only file without a trailing newline. |
||
} // namespace Halide |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1586,11 +1586,11 @@ WasmModule WasmModule::compile( | |
#if !defined(WITH_WABT) | ||
user_error << "Cannot run JITted WebAssembly without configuring a WebAssembly engine."; | ||
return WasmModule(); | ||
#endif | ||
|
||
#else | ||
WasmModule wasm_module; | ||
wasm_module.contents = new WasmModuleContents(module, arguments, fn_name, jit_externs, extern_deps); | ||
return wasm_module; | ||
#endif | ||
} | ||
Comment on lines
-1589
to
1594
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Similar to above: unreachable code. |
||
|
||
/** Run generated previously compiled wasm code with a set of arguments. */ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ouch. I wonder if this was a bad merge. Probably worth turning on this warning explicitly.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yow. I'm genuinely surprised this is merely a warning.