Skip to content

Commit aacc5f7

Browse files
committed
Add C-SKY v2 big-endian support.
1 parent b72433b commit aacc5f7

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

platform/linux/platform_linux.cpp

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -671,6 +671,18 @@ extern "C"
671671
BinaryViewType::RegisterPlatform("ELF", 3, platform);
672672
}
673673

674+
Ref<Architecture> cskyv2be = Architecture::GetByName("csky_be");
675+
if (cskyv2be)
676+
{
677+
Ref<Platform> platform;
678+
679+
platform = new LinuxCSkyV2Platform(cskyv2be, "linux-csky_be");
680+
Platform::Register("linux", platform);
681+
// Linux binaries sometimes have an OS identifier of zero, even though 3 is the correct one
682+
BinaryViewType::RegisterPlatform("ELF", 0, platform);
683+
BinaryViewType::RegisterPlatform("ELF", 3, platform);
684+
}
685+
674686
Ref<Architecture> nds32 = Architecture::GetByName("nds32");
675687
if (nds32)
676688
{

0 commit comments

Comments
 (0)