Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > Help me!
2024-07-28 23:56
JackAsser

Registered: Jun 2002
Posts: 2038
Help me!

So I'm coding some EasyFlash stuff so most often the kernel is swapped in ($01 = #$37).

Take a look at the following chis (VICE cpu history): https://i.postimg.cc/sg9xL7xV/temp-Image-Gb-W5z-N.avif

I'm putting a CR to $ffd2 and all goes well until it hits $ed41 where the CPU fetches a JAM-instruction. How's that even possible?! The ROM can't be altered. Comparing to ROM-listings it should do a JSR $EE97 there.

There is a SEI just infront if that matters.

(Only tested in HEAD VICE and some older version like 3.6 and 3.8). Could it be an emulation bug?

((Nevermind the .arbX label, it's just my loaded labels from the assembler. In the ROM it's just BIT $94)).

It happens VERY seldom.
 
... 20 posts hidden. Click here to view all posts....
 
2024-07-30 10:39
Krill

Registered: Apr 2002
Posts: 3005
Quoting JackAsser
Imo it shouldn’t be line buffered at all - ever. When you send a character to a printer connected to a c64, that character is printed directly. And so should it behave when emulated to a file also.
Ok, fair point. =)
2024-07-30 14:49
chatGPZ

Registered: Dec 2001
Posts: 11443
Quote:
Anyways, VICE works fine. I need to submit a patch for a proper fflush() on each $ffd2 though. Currently on my mac it's line buffered which is a bit annoying.

I believe those extra fflush calls are what screws up your warpmode in windows :=)
2024-07-30 15:34
JackAsser

Registered: Jun 2002
Posts: 2038
Quote: Quote:
Anyways, VICE works fine. I need to submit a patch for a proper fflush() on each $ffd2 though. Currently on my mac it's line buffered which is a bit annoying.

I believe those extra fflush calls are what screws up your warpmode in windows :=)


Highely likely. I wouldn’t use fflush explicitly though now that I think of it.

I’d do a setvbuf to turn off buffering on the stream, and use fcntl() with O_DSYNC | O_RSYNC on the underlying FD. The OS block-level cache should be able to ensure the same speed even if the stream itself is unbuffered.

Will try on my already patched VICE-install. :)
2024-07-30 16:29
chatGPZ

Registered: Dec 2001
Posts: 11443
feel free to examine other fflush calls in the log code :)
2024-07-30 16:38
JackAsser

Registered: Jun 2002
Posts: 2038
Yeah. Also, would be fun to do a gprof in warpmode to see the bottlenecks. :)
Previous - 1 | 2 | 3 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Mike
zscs
Guests online: 183
Top Demos
1 Next Level  (9.7)
2 Codeboys & Endians  (9.7)
3 13:37  (9.7)
4 Coma Light 13  (9.6)
5 Mojo  (9.6)
6 Edge of Disgrace  (9.6)
7 Uncensored  (9.6)
8 What Is The Matrix 2  (9.6)
9 Comaland 100%  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 Nine  (9.7)
2 Trippy Tea  (9.7)
3 Layers  (9.6)
4 Party Elk 2  (9.6)
5 Cubic Dream  (9.6)
6 Copper Booze  (9.6)
7 The Boiling Bar  (9.5)
8 Libertongo  (9.5)
9 Ten  (9.5)
10 Dawnfall V1.1  (9.5)
Top Groups
1 Oxyron  (9.3)
2 Booze Design  (9.3)
3 Performers  (9.3)
4 Censor Design  (9.2)
5 Crest  (9.2)
Top NTSC-Fixers
1 Pudwerx  (10)
2 Stormbringer  (9.7)
3 Fungus  (9.7)
4 Booze  (9.5)
5 Grim Reaper  (9.3)

Home - Disclaimer
Copyright © No Name 2001-2025
Page generated in: 0.135 sec.