Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update PCEAS to build up to 8MByte ROMs. #25

Merged
merged 7 commits into from
Mar 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
runs-on: ${{ matrix.os }}
steps:
- name: Check out code from the repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Build on Linux
Expand All @@ -45,7 +45,7 @@ jobs:
make
echo Build Complete
- name: Archive toolchain
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: toolchain-${{ matrix.os }}
path: |
Expand All @@ -63,9 +63,9 @@ jobs:
needs: build
steps:
- name: Check out code from the repository
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Get previoulsy built artifacts
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: toolchain-${{ matrix.os }}
- name: Restore Execute Flags
Expand Down Expand Up @@ -108,9 +108,9 @@ jobs:
needs: build
steps:
- name: Check out code from the repository
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Get previously built artifacts
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: toolchain-${{ matrix.os }}
- name: Package ${{ matrix.os }}
Expand All @@ -130,7 +130,7 @@ jobs:
make package
echo Package Complete
- name: Archive package
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: package-${{ matrix.os }}
path: |
Expand All @@ -143,17 +143,17 @@ jobs:
if: github.ref == 'refs/heads/master' && github.event_name != 'pull_request'
steps:
- name: Check out code from the repository
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Get previoulsy built artifacts win64
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: package-windows-2022
- name: Get previously built artifacts macos
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: package-macos-12
- name: Get previously built artifacts linux
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
with:
name: package-ubuntu-20.04
# https://github.com/pyTooling/Actions/tree/main/releaser
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
uses: github/codeql-action/init@v3
with:
# debug: true
languages: ${{ matrix.language }}
Expand All @@ -58,7 +58,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2
uses: github/codeql-action/autobuild@v3

# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
Expand All @@ -71,4 +71,4 @@ jobs:
# ./location_of_script_within_repo/buildscript.sh

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v3
2 changes: 1 addition & 1 deletion examples/asm/elmer/include/cdrom.asm
Original file line number Diff line number Diff line change
Expand Up @@ -1312,7 +1312,7 @@ cdr_ad_trans .proc

; Send SCSI command.

.send_command: ldx.l <_bx ; Set the ADPCM RAM desination address.
.send_command: ldx.l <_bx ; Set the ADPCM RAM destination address.
ldy.h <_bx
jsr adpcm_set_dst

Expand Down
10 changes: 5 additions & 5 deletions examples/asm/elmer/include/core-startup.asm
Original file line number Diff line number Diff line change
Expand Up @@ -415,20 +415,20 @@ core_hw_reset: sei ; Disable interrupts.

; Read the already-assembled equates for the kernel code.
;
; N.B. The area() changes are only here to test PCEAS!
; N.B. The tag() changes are only here to test PCEAS!

!: .area -1 ; Tag the STAGE1 symbols.
!: .settag -1 ; Tag the STAGE1 symbols.

include "core-stage1.s"

.area area(!-) ; Restore previous area.
.settag tagof(!-) ; Restore previous area.

.if (core_kernel != core_ram1st)
.fail Stage1 kernel has not been built with the same core_ram1st!
.endif

.if (area(core_kernel) != -1)
.fail .AREA is not working correctly!
.if (tagof(*) != 0) + (tagof(core_kernel) != -1)
.fail .TAG is not working correctly!
.endif

.else USING_STAGE1
Expand Down
6 changes: 6 additions & 0 deletions src/Make_src.inc
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ CDEFS =
CFLAGS = -Wall -g -O2
CFLAGS += -DGIT_VERSION="\"$(GIT_VERSION)\""
CFLAGS += -DGIT_DATE="\"$(GIT_DATE)\""
CXXFLAGS += -DGIT_VERSION="\"$(GIT_VERSION)\""
CXXFLAGS += -DGIT_DATE="\"$(GIT_DATE)\""
LDFLAGS = -g

#
Expand All @@ -29,3 +31,7 @@ EXESUFFIX =
CP = cp
RM = rm -f
CC = cc
CXX = c++
AWK = awk
LEX = lex
YACC = yacc
3 changes: 2 additions & 1 deletion src/Maketarg.inc
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,5 @@ endif

%.o: %.c
$(CC) $(CDEFS) $(CFLAGS) -c $< -o $@

%.o: %.cc
$(CXX) $(CDEFS) $(CXXFLAGS) -c $< -o $@
8 changes: 4 additions & 4 deletions src/mkit/as/code.c
Original file line number Diff line number Diff line change
Expand Up @@ -768,8 +768,8 @@ getoperand(int *ip, int flag, int last_char)
if (mode == (ABS | ABS_X | ABS_Y | ZP | ZP_X | ZP_Y)) {
/* was there an undefined or undefined-this-pass symbol? */
if (undef || notyetdef ||
((value & 0x007FFF00) != machine->ram_base)) {
// ((value & 0x007FFF00) && ((value & 0x007FFF00) != machine->ram_base))) {
((value & 0x3FFFFF00) != machine->ram_base)) {
// ((value & 0x3FFFFF00) && ((value & 0x3FFFFF00) != machine->ram_base))) {
/* use ABS addressing, if available */
if (flag & ABS)
mode &= ~ZP;
Expand Down Expand Up @@ -896,7 +896,7 @@ getoperand(int *ip, int flag, int last_char)
value++;
}
/* check address validity */
if ((value & 0x007FFF00) && ((value & 0x007FFF00) != machine->ram_base))
if ((value & 0x3FFFFF00) && ((value & 0x3FFFFF00) != machine->ram_base))
error("Incorrect zero page address!");
}

Expand All @@ -911,7 +911,7 @@ getoperand(int *ip, int flag, int last_char)
error("Instruction extension not supported in immediate mode!");
else {
/* check value validity */
if (((value & 0x007FFF00) > 0xFF) && ((value & 0x007FFF00) < 0x007FFF00))
if (((value & 0x3FFFFF00) > 0xFF) && ((value & 0x3FFFFF00) < 0x3FFFFF00))
error("Incorrect immediate value!");
}
}
Expand Down
Loading