P4 to Git Change 1451958 by skudchad@skudchad_test_win_opencl2 on 2017/08/25 19:27:11
SWDEV-116136 - Support -Og for Clang
ReviewBoardURL = http://ocltc.amd.com/reviews/r/13341/diff/
Affected files ...
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/codegen.cpp#3 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/linker.cpp#4 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/opt_level.cpp#2 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/opt_level.hpp#3 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/common/optimizer.cpp#3 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/gpu/hsail_be.cpp#5 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/backends/gpu/scwrapper/scState.cpp#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/utils/OPTIONS.def#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/utils/options.cpp#5 edit
... //depot/stg/opencl/drivers/opencl/compiler/legacy-lib/utils/options.hpp#5 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/codegen.cpp#73 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/linker.cpp#157 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/opt_level.cpp#33 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/opt_level.hpp#7 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/common/optimizer.cpp#30 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/backends/gpu/hsail_be.cpp#68 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/OPTIONS.def#136 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/options.cpp#42 edit
... //depot/stg/opencl/drivers/opencl/compiler/lib/utils/options.hpp#19 edit
[ROCm/clr commit: 2c0b212d96]
This commit is contained in:
@@ -25,25 +25,29 @@ using namespace amdcl;
|
||||
using namespace llvm;
|
||||
|
||||
static OptLevel* getOptLevel(amd::option::Options* Options, bool isGPU) {
|
||||
switch(Options->oVariables->OptLevel) {
|
||||
switch(Options->oVariables->OptLevel) {
|
||||
case amd::option::OPT_O0:
|
||||
return (isGPU) ? new GPUO0OptLevel(Options) : new O0OptLevel(Options);
|
||||
return (isGPU) ? new GPUO0OptLevel(Options) : new O0OptLevel(Options);
|
||||
case amd::option::OPT_O1:
|
||||
return new O1OptLevel(Options);
|
||||
return new O1OptLevel(Options);
|
||||
default:
|
||||
assert(!"Found an invalid optimization level!");
|
||||
assert(!"Found an invalid optimization level!");
|
||||
case amd::option::OPT_O2:
|
||||
return new O2OptLevel(Options);
|
||||
return new O2OptLevel(Options);
|
||||
case amd::option::OPT_OG:
|
||||
return new OgOptLevel(Options);
|
||||
case amd::option::OPT_O3:
|
||||
return new O3OptLevel(Options);
|
||||
return new O3OptLevel(Options);
|
||||
case amd::option::OPT_O4:
|
||||
return new O4OptLevel(Options);
|
||||
return new O4OptLevel(Options);
|
||||
case amd::option::OPT_O5:
|
||||
case amd::option::OPT_OS:
|
||||
return new OsOptLevel(Options);
|
||||
}
|
||||
assert(!"Unreachable!");
|
||||
return NULL;
|
||||
return new OsOptLevel(Options);
|
||||
}
|
||||
assert(!"Unreachable!");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
int
|
||||
CPUOptimizer::preOptimizer(llvm::Module* M)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user