Apply constexpr on global constant varaibles

When HIP_ENABLE_DEFERRED_LOADING=0, many global variables will be
referenced but they are not initialized in that early time. The patch
will use constexpr to initialze global constant varables in compile
time.

Change-Id: I9d538b7abc6a0ce700ec3332b97fc144db5fc1ef


[ROCm/clr commit: fdef6f722f]
这个提交包含在:
Tao Sang 编写, Tao Sang 于 2020-07-22 22:14:13 -04:00 提交
1 父节点 11f8a869f1
当前提交 44eb207f8d
62 个文件已更改
+224 -227

没有与搜索条件相匹配的文件

+2 -2
查看文件
@@ -234,8 +234,8 @@ int PrintfDbg::checkVectorSpecifier(const std::string& fmt, size_t startPos, siz
return vectorSize;
}
static const size_t ConstStr = 0xffffffff;
static const char Separator[] = ",\0";
static constexpr size_t ConstStr = 0xffffffff;
static constexpr char Separator[] = ",\0";
size_t PrintfDbg::outputArgument(const std::string& fmt, bool printFloat, size_t size,
const uint32_t* argument) const {