Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion source/loader/layers/sanitizer/asan_interceptor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ struct DeviceInfo {
uptr ShadowOffsetEnd = 0;

// Device features
bool IsSupportSharedSystemUSM;
bool IsSupportSharedSystemUSM = false;

ur_mutex Mutex;
std::queue<std::shared_ptr<AllocInfo>> Quarantine;
Expand Down
2 changes: 1 addition & 1 deletion source/loader/layers/sanitizer/stacktrace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ void StackTrace::print() const {
uptr Offset;
ParseBacktraceInfo(BI, ModuleName, Offset);
if (SymbolizeCode(ModuleName, Offset, Result)) {
SourceInfo SrcInfo = ParseSymbolizerOutput(Result);
SourceInfo SrcInfo = ParseSymbolizerOutput(std::move(Result));
if (SrcInfo.file != "??") {
getContext()->logger.always(" #{} in {} {}:{}:{}", index,
SrcInfo.function, SrcInfo.file,
Expand Down
2 changes: 1 addition & 1 deletion test/layers/validation/fixtures.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ inline ur_result_t genericSuccessCallback(void *) { return UR_RESULT_SUCCESS; };
// This returns valid (non-null) handles that we can safely leak.
inline ur_result_t fakeContext_urContextCreate(void *pParams) {
static std::atomic_int handle = 42;
auto params = *static_cast<ur_context_create_params_t *>(pParams);
const auto &params = *static_cast<ur_context_create_params_t *>(pParams);
// There are two casts because windows doesn't implicitly extend the 32 bit
// result of atomic_int::operator++.
**params.pphContext =
Expand Down
2 changes: 1 addition & 1 deletion test/layers/validation/leaks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

// We need a fake handle for the below adapter leak test.
inline ur_result_t fakeAdapter_urAdapterGet(void *pParams) {
auto params = *static_cast<ur_adapter_get_params_t *>(pParams);
const auto &params = *static_cast<ur_adapter_get_params_t *>(pParams);
**params.pphAdapters = reinterpret_cast<ur_adapter_handle_t>(0x1);
return UR_RESULT_SUCCESS;
}
Expand Down
4 changes: 2 additions & 2 deletions test/loader/handles/fixtures.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#endif

ur_result_t replace_urPlatformGet(void *pParams) {
auto params = *static_cast<ur_platform_get_params_t *>(pParams);
const auto &params = *static_cast<ur_platform_get_params_t *>(pParams);

if (*params.ppNumPlatforms) {
**params.ppNumPlatforms = 1;
Expand All @@ -29,7 +29,7 @@ ur_result_t replace_urPlatformGet(void *pParams) {
}

ur_result_t replace_urDeviceGetInfo(void *pParams) {
auto params = *static_cast<ur_device_get_info_params_t *>(pParams);
const auto &params = *static_cast<ur_device_get_info_params_t *>(pParams);
if (*params.ppropName == UR_DEVICE_INFO_PLATFORM) {
if (*params.ppPropSizeRet) {
**params.ppPropSizeRet = sizeof(ur_platform_handle_t);
Expand Down