Skip to content

Commit 672c728

Browse files
committed
Merge branch 'sycl' into pietro/comp_link
2 parents 2f25751 + dcb975d commit 672c728

File tree

394 files changed

+5809
-2400
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

394 files changed

+5809
-2400
lines changed

.github/workflows/docs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ jobs:
6565
fetch-depth: 1
6666
- name: Get subprojects that have doc changes
6767
id: docs-changed-subprojects
68-
uses: tj-actions/changed-files@v44
68+
uses: tj-actions/changed-files@v45
6969
with:
7070
files_yaml: |
7171
llvm:

.github/workflows/pr-code-format.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232

3333
- name: Get changed files
3434
id: changed-files
35-
uses: tj-actions/changed-files@v44
35+
uses: tj-actions/changed-files@v45
3636
with:
3737
separator: ","
3838
skip_initial_fetch: true

.github/workflows/release-binaries.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -428,7 +428,7 @@ jobs:
428428

429429
- name: Attest Build Provenance
430430
id: provenance
431-
uses: actions/attest-build-provenance@897ed5eab6ed058a474202017ada7f40bfa52940 # v1.0.0
431+
uses: actions/attest-build-provenance@1c608d11d69870c2092266b3f9a6f3abbf17002c # v1.4.3
432432
with:
433433
subject-path: ${{ needs.prepare.outputs.release-binary-filename }}
434434

.github/workflows/release-sources.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ jobs:
9292
- name: Attest Build Provenance
9393
if: github.event_name != 'pull_request'
9494
id: provenance
95-
uses: actions/attest-build-provenance@897ed5eab6ed058a474202017ada7f40bfa52940 # v1.0.0
95+
uses: actions/attest-build-provenance@1c608d11d69870c2092266b3f9a6f3abbf17002c # v1.4.3
9696
with:
9797
subject-path: "*.xz"
9898
- if: github.event_name != 'pull_request'

.github/workflows/scorecard.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
persist-credentials: false
3737

3838
- name: "Run analysis"
39-
uses: ossf/scorecard-action@dc50aa9510b46c811795eb24b2f1ba02a914e534 # v2.3.3
39+
uses: ossf/scorecard-action@62b2cac7ed8198b15735ed49ab1e5cf35480ba46 # v2.4.0
4040
with:
4141
results_file: results.sarif
4242
results_format: sarif
@@ -57,6 +57,6 @@ jobs:
5757

5858
# Upload the results to GitHub's code scanning dashboard.
5959
- name: "Upload to code-scanning"
60-
uses: github/codeql-action/upload-sarif@b611370bb5703a7efb587f9d136a52ea24c5c38c # v3.25.11
60+
uses: github/codeql-action/upload-sarif@e2b3eafc8d227b0241d48be5f425d47c2d750a13 # v3.26.10
6161
with:
6262
sarif_file: results.sarif

.github/workflows/sycl-linux-run-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ permissions:
151151

152152
jobs:
153153
run:
154-
if: inputs.skip_run == 'false'
154+
if: github.event_name == 'workflow_dispatch' || inputs.skip_run == 'false'
155155
name: ${{ inputs.name }}
156156
runs-on: ${{ fromJSON(inputs.runner) }}
157157
container:

.github/workflows/sycl-nightly.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ jobs:
198198
echo "TAG=$(date +'%Y-%m-%d')-${GITHUB_SHA::7}" >> "$GITHUB_OUTPUT"
199199
fi
200200
- name: Upload binaries
201-
uses: softprops/action-gh-release@a74c6b72af54cfa997e81df42d94703d6313a2d0
201+
uses: softprops/action-gh-release@c062e08bd532815e2082a85e87e3ef29c3e6d191
202202
with:
203203
files: |
204204
sycl_linux.tar.gz

clang/include/clang/Driver/ToolChain.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -781,6 +781,10 @@ class ToolChain {
781781
virtual void AddHIPIncludeArgs(const llvm::opt::ArgList &DriverArgs,
782782
llvm::opt::ArgStringList &CC1Args) const;
783783

784+
/// Add arguments to use SYCL specific includes.
785+
virtual void AddSYCLIncludeArgs(const llvm::opt::ArgList &DriverArgs,
786+
llvm::opt::ArgStringList &CC1Args) const;
787+
784788
/// Add arguments to use MCU GCC toolchain includes.
785789
virtual void AddIAMCUIncludeArgs(const llvm::opt::ArgList &DriverArgs,
786790
llvm::opt::ArgStringList &CC1Args) const;

clang/lib/Driver/Driver.cpp

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7446,8 +7446,30 @@ void Driver::BuildActions(Compilation &C, DerivedArgList &Args,
74467446
if (Args.hasArg(options::OPT_fsycl_link_EQ) &&
74477447
Args.hasArg(options::OPT_fintelfpga)) {
74487448
// Wrap the object when creating an FPGA AOCX or AOCR binary.
7449-
auto *BC = C.MakeAction<OffloadWrapperJobAction>(LI, types::TY_LLVM_BC);
7450-
auto *ASM = C.MakeAction<BackendJobAction>(BC, types::TY_PP_Asm);
7449+
// When the input file is an AOCR (early) archive, the unbundled host
7450+
// binary consists of a list of objects. We cannot directly wrap that
7451+
// binary to be consumed later - this has to go through each listed
7452+
// object.
7453+
bool FPGAEarly = true;
7454+
if (auto *A = C.getInputArgs().getLastArg(options::OPT_fsycl_link_EQ))
7455+
FPGAEarly = A->getValue() == StringRef("early");
7456+
7457+
Action *WrapperAction;
7458+
if ((LI->getType() == types::TY_FPGA_AOCR ||
7459+
LI->getType() == types::TY_FPGA_AOCR_EMU) &&
7460+
!FPGAEarly) {
7461+
auto *RenameAction = C.MakeAction<FileTableTformJobAction>(
7462+
LI, types::TY_Tempfilelist, types::TY_Tempfilelist);
7463+
RenameAction->addRenameColumnTform(FileTableTformJobAction::COL_ZERO,
7464+
FileTableTformJobAction::COL_CODE);
7465+
ActionList WrapperItems({RenameAction});
7466+
WrapperAction = C.MakeAction<OffloadWrapperJobAction>(
7467+
WrapperItems, types::TY_LLVM_BC);
7468+
} else
7469+
WrapperAction =
7470+
C.MakeAction<OffloadWrapperJobAction>(LI, types::TY_LLVM_BC);
7471+
auto *ASM =
7472+
C.MakeAction<BackendJobAction>(WrapperAction, types::TY_PP_Asm);
74517473
auto *OBJ = C.MakeAction<AssembleJobAction>(ASM, types::TY_Object);
74527474
OffloadAction::HostDependence HDep(
74537475
*OBJ, *C.getSingleOffloadToolChain<Action::OFK_Host>(),

clang/lib/Driver/ToolChain.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1519,6 +1519,9 @@ void ToolChain::AddCudaIncludeArgs(const ArgList &DriverArgs,
15191519
void ToolChain::AddHIPIncludeArgs(const ArgList &DriverArgs,
15201520
ArgStringList &CC1Args) const {}
15211521

1522+
void ToolChain::AddSYCLIncludeArgs(const ArgList &DriverArgs,
1523+
ArgStringList &CC1Args) const {}
1524+
15221525
llvm::SmallVector<ToolChain::BitCodeLibraryInfo, 12>
15231526
ToolChain::getDeviceLibs(
15241527
const ArgList &DriverArgs,

0 commit comments

Comments
 (0)