Skip to content

Commit

Permalink
#0: Kill l1_test_data_only (#14219)
Browse files Browse the repository at this point in the history
  • Loading branch information
nathan-TT authored Oct 24, 2024
1 parent 3e188b7 commit 9e8d1b5
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 11 deletions.
Original file line number Diff line number Diff line change
@@ -1,15 +1,18 @@
// SPDX-FileCopyrightText: © 2023 Tenstorrent Inc.
// SPDX-FileCopyrightText: © 2023, 2024 Tenstorrent Inc.
//
// SPDX-License-Identifier: Apache-2.0

// NULL kernel is not 0, subtract off overhead
#if KERNEL_BYTES > 16
constexpr uint32_t empty_kernel_bytes = 16;
uint8_t data1[KERNEL_BYTES - empty_kernel_bytes] __attribute__ ((section ("l1_data_test_only"))) __attribute__((used));
// An empty kernel is 16 bytes, so only pad above that to fake a
// bigger kernel.
#define EMPTY_KERNEL_BYTES 16
#if KERNEL_BYTES > EMPTY_KERNEL_BYTES
[[gnu::section(".text"), gnu::used]]
static uint8_t lorem_ipsum[KERNEL_BYTES - EMPTY_KERNEL_BYTES];
#endif

#ifdef KERNEL_GLOBAL
volatile uint32_t global = 4;
[[gnu::section(".data"), gnu::used]]
static uint32_t global;
#endif

#ifdef COMPILE_FOR_TRISC
Expand Down
5 changes: 0 additions & 5 deletions tt_metal/hw/toolchain/sections.ld
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,6 @@ SECTIONS
ASSERT(SIZEOF(.init.fini) == 0, ".init/.fini sections have contents");
} > REGION_CODE

l1_data :
{
*(l1_data_test_only)
} > REGION_CODE

. = ALIGN(. + MEM_PAD, MEM_ALIGN);

#if defined(TYPE_FIRMWARE)
Expand Down

0 comments on commit 9e8d1b5

Please sign in to comment.