-
Notifications
You must be signed in to change notification settings - Fork 117
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure a consistent line-endings policy
I just went to change one line in a file, then found out the whole file changed since it was committed differently to my local system, and we don't do normalisation yet. This fixes that. Here we add a .gitattributes file at the top level with the policy `* text=auto` which roughly translates as files that git considers "text" are stored internally in history as LF and checked out according to local user preference (which might be CRLF on a certain person's Win32 box, for example). In addition to the new .gitattributes, files that had CRLF line-endings in the history have been renormalized with `git add --renormalize .`. This should make cross-platform development easier while respecting local configs. When in Rome...
- Loading branch information
Showing
5 changed files
with
458 additions
and
457 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* text=auto |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
//===--------- ur_level_zero.cpp - Level Zero Adapter ---------------------===// | ||
// | ||
// Copyright (C) 2023 Intel Corporation | ||
// | ||
// Part of the Unified-Runtime Project, under the Apache License v2.0 with LLVM | ||
// Exceptions. See LICENSE.TXT | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===----------------------------------------------------------------------===// | ||
|
||
#include <algorithm> | ||
#include <climits> | ||
#include <string.h> | ||
|
||
#include "ur_level_zero.hpp" | ||
|
||
// Define the static class field | ||
std::mutex ZeCall::GlobalLock; | ||
//===--------- ur_level_zero.cpp - Level Zero Adapter ---------------------===// | ||
// | ||
// Copyright (C) 2023 Intel Corporation | ||
// | ||
// Part of the Unified-Runtime Project, under the Apache License v2.0 with LLVM | ||
// Exceptions. See LICENSE.TXT | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===----------------------------------------------------------------------===// | ||
|
||
#include <algorithm> | ||
#include <climits> | ||
#include <string.h> | ||
|
||
#include "ur_level_zero.hpp" | ||
|
||
// Define the static class field | ||
std::mutex ZeCall::GlobalLock; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,38 +1,38 @@ | ||
//===--------- ur_level_zero.hpp - Level Zero Adapter ---------------------===// | ||
// | ||
// Copyright (C) 2023 Intel Corporation | ||
// | ||
// Part of the Unified-Runtime Project, under the Apache License v2.0 with LLVM | ||
// Exceptions. See LICENSE.TXT | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===----------------------------------------------------------------------===// | ||
#pragma once | ||
|
||
#include <cassert> | ||
#include <cinttypes> | ||
#include <list> | ||
#include <map> | ||
#include <stdarg.h> | ||
#include <string> | ||
#include <unordered_map> | ||
#include <vector> | ||
|
||
#include <ur/ur.hpp> | ||
#include <ur_api.h> | ||
#include <ze_api.h> | ||
#include <zes_api.h> | ||
|
||
#include "common.hpp" | ||
#include "context.hpp" | ||
#include "device.hpp" | ||
#include "event.hpp" | ||
#include "image.hpp" | ||
#include "kernel.hpp" | ||
#include "memory.hpp" | ||
#include "physical_mem.hpp" | ||
#include "platform.hpp" | ||
#include "program.hpp" | ||
#include "queue.hpp" | ||
#include "sampler.hpp" | ||
#include "usm.hpp" | ||
//===--------- ur_level_zero.hpp - Level Zero Adapter ---------------------===// | ||
// | ||
// Copyright (C) 2023 Intel Corporation | ||
// | ||
// Part of the Unified-Runtime Project, under the Apache License v2.0 with LLVM | ||
// Exceptions. See LICENSE.TXT | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===----------------------------------------------------------------------===// | ||
#pragma once | ||
|
||
#include <cassert> | ||
#include <cinttypes> | ||
#include <list> | ||
#include <map> | ||
#include <stdarg.h> | ||
#include <string> | ||
#include <unordered_map> | ||
#include <vector> | ||
|
||
#include <ur/ur.hpp> | ||
#include <ur_api.h> | ||
#include <ze_api.h> | ||
#include <zes_api.h> | ||
|
||
#include "common.hpp" | ||
#include "context.hpp" | ||
#include "device.hpp" | ||
#include "event.hpp" | ||
#include "image.hpp" | ||
#include "kernel.hpp" | ||
#include "memory.hpp" | ||
#include "physical_mem.hpp" | ||
#include "platform.hpp" | ||
#include "program.hpp" | ||
#include "queue.hpp" | ||
#include "sampler.hpp" | ||
#include "usm.hpp" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,24 @@ | ||
|
||
//===--------- ur.cpp - Unified Runtime ----------------------------------===// | ||
// | ||
// Copyright (C) 2023 Intel Corporation | ||
// | ||
// Part of the Unified-Runtime Project, under the Apache License v2.0 with LLVM | ||
// Exceptions. See LICENSE.TXT | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===----------------------------------------------------------------------===// | ||
|
||
#include "ur.hpp" | ||
#include <cassert> | ||
|
||
// Controls tracing UR calls from within the UR itself. | ||
bool PrintTrace = [] { | ||
const char *PiRet = std::getenv("SYCL_PI_TRACE"); | ||
const char *Trace = PiRet ? PiRet : nullptr; | ||
const int TraceValue = Trace ? std::stoi(Trace) : 0; | ||
if (TraceValue == -1 || TraceValue == 2) { // Means print all traces | ||
return true; | ||
} | ||
return false; | ||
}(); | ||
|
||
//===--------- ur.cpp - Unified Runtime ----------------------------------===// | ||
// | ||
// Copyright (C) 2023 Intel Corporation | ||
// | ||
// Part of the Unified-Runtime Project, under the Apache License v2.0 with LLVM | ||
// Exceptions. See LICENSE.TXT | ||
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception | ||
// | ||
//===----------------------------------------------------------------------===// | ||
|
||
#include "ur.hpp" | ||
#include <cassert> | ||
|
||
// Controls tracing UR calls from within the UR itself. | ||
bool PrintTrace = [] { | ||
const char *PiRet = std::getenv("SYCL_PI_TRACE"); | ||
const char *Trace = PiRet ? PiRet : nullptr; | ||
const int TraceValue = Trace ? std::stoi(Trace) : 0; | ||
if (TraceValue == -1 || TraceValue == 2) { // Means print all traces | ||
return true; | ||
} | ||
return false; | ||
}(); |
Oops, something went wrong.