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
Dieser Commit ist enthalten in:
Tao Sang verfasst und Tao Sang committed 2020-07-22 22:14:13 -04:00
1 Ursprung 2800fc2fa3
Commit fdef6f722f
62 Dateien geändert
+224 -227

Keine Dateien entsprechen Ihrer Suche

+1 -1
Datei anzeigen
@@ -170,7 +170,7 @@ bool Segment::freeze(bool destroySysmem) {
return result;
}
const static char* Carrizo = "Carrizo";
static constexpr const char* Carrizo = "Carrizo";
HSAILProgram::HSAILProgram(Device& device, amd::Program& owner)
: Program(device, owner),
rawBinary_(nullptr),