38 lines
531 B
C
Executable File
38 lines
531 B
C
Executable File
// SPDX-License-Identifier: MIT
|
||
//
|
||
// boot/w65c816s.h
|
||
// Defines for the 65C816 architecture
|
||
//
|
||
// Copyright © 2024 Kyle J Cardoza <Kyle.Cardoza@icloud.com>
|
||
|
||
#ifdef __CALYPSI_ASSEMBLER__
|
||
|
||
#define native_mode \
|
||
clc \
|
||
xce
|
||
|
||
#define long_a rep #0x20
|
||
|
||
#define short_a sep #0x20
|
||
|
||
#define long_i rep #0x10
|
||
|
||
#define short_i sep #0x10
|
||
|
||
#define save_registers \
|
||
php \
|
||
long_a \
|
||
long_i \
|
||
pha \
|
||
phx \
|
||
phy
|
||
|
||
#define restore_registers \
|
||
long_a \
|
||
long_i \
|
||
ply \
|
||
plx \
|
||
pla \
|
||
plp
|
||
|
||
#endif |