English Amiga Board


Go Back   English Amiga Board > Coders > Coders. Asm / Hardware

 
 
Thread Tools
Old 12 January 2012, 17:29   #1
TheDarkCoder
Registered User
 
Join Date: Dec 2007
Location: Dark Kingdom
Posts: 213
Suggestion for ASM Usage running example

This question is not specifically Amiga-related, I hope nobody is bothered.
I am giving a course on assembly programming. The course is focused on the MIPS architecture (choice forced by several constraints), but I tried also to give an overview about other approaches, such as m68k of course.

In the final lesson, I would like to show a program written in ASM which exploit something feasible in asm only. It would be very nice if the source code of the program is available.
I ask for some suggestion.
Since it's difficult to measure speed, I was thinking to show some really compact program, such as a 4k intro.
It should run on my windows laptop, which is equipped with WinUAE, so any Amiga prod should be ok. Of course, a MIPS program would also be nice but I don't know any.

Any suggestion is welcome!
TheDarkCoder is offline  
Old 12 January 2012, 18:30   #2
pmc
gone
 
pmc's Avatar
 
Join Date: Apr 2007
Location: completely gone
Posts: 1,596
If you're looking for a killer 4kb then how about Ikadalawampu by Loonies? Try doing that in anything other than asm!

http://www.pouet.net/prod.php?which=54561

Superb in every way.

Last edited by pmc; 12 January 2012 at 18:39. Reason: Thought of something
pmc is offline  
Old 13 January 2012, 06:42   #3
xaind
Registered User
 
Join Date: Apr 2006
Location: Sydney / Australia
Posts: 113
Ikadalawampu is very impressive. Has anyone managed to figure out what settings to use to make it work in WinUAE?
xaind is offline  
Old 13 January 2012, 10:37   #4
Leffmann
 
Join Date: Jul 2008
Location: Sweden
Posts: 2,269
Any config with AGA, 32M RAM, 020 and FPU. It needs about a minute of precalc before it starts.
Leffmann is offline  
Old 13 January 2012, 10:43   #5
Photon
Moderator
 
Photon's Avatar
 
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,652
Very impressive for an Amiga 4K. Most OCS demos are impossible to write in a high-level language, but few have sources.

A 4k is a good idea cos even if the source isn't available it should be doable to decrunch and resource the 7-12K of code in a relatively short time.

If you can decrunch any demo in f.ex. PowerPacker or whatever, then you can always disassemble the binary and show the code that way.
Photon is offline  
Old 13 January 2012, 22:17   #6
Lonewolf10
AMOS Extensions Developer
 
Lonewolf10's Avatar
 
Join Date: Jun 2007
Location: near Cambridge, UK
Age: 44
Posts: 1,924
Quote:
Originally Posted by Leffmann View Post
Any config with AGA, 32M RAM, 020 and FPU. It needs about a minute of precalc before it starts.
Why does it need so much RAM? The initial file is only 4K, or has the data within it been compressed multiple times??
I DL'ed the file but struggled to get it to work yesterday and so watched it on YouTube today ( [ Show youtube player ]). Very impressive.


Regards,
Lonewolf10
Lonewolf10 is offline  
Old 13 January 2012, 22:35   #7
StingRay
move.l #$c0ff33,throat
 
StingRay's Avatar
 
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
Quote:
Originally Posted by Lonewolf10 View Post
Why does it need so much RAM? The initial file is only 4K, or has the data within it been compressed multiple times??
Because the music and data for the effects (textures, tables etc. pp.) have to be precalculated. And this needs memory. The file size has nothing to do with the memory requirements and it's of course not packed multiple times as that wouldn't make sense at all.
StingRay is offline  
Old 13 January 2012, 22:50   #8
Lonewolf10
AMOS Extensions Developer
 
Lonewolf10's Avatar
 
Join Date: Jun 2007
Location: near Cambridge, UK
Age: 44
Posts: 1,924
Quote:
Originally Posted by StingRay View Post
Because the music and data for the effects (textures, tables etc. pp.) have to be precalculated. And this needs memory.
Ok. That is something I will keep in mind in future - create tables in RAM rather than wasting bytes in the executable


Regards,
Lonewolf10
Lonewolf10 is offline  
Old 14 January 2012, 23:29   #9
Photon
Moderator
 
Photon's Avatar
 
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,652
Quote:
Originally Posted by StingRay View Post
Because the music and data for the effects (textures, tables etc. pp.) have to be precalculated.
Which textures?

And 15MB+ precalced music instead of 1.5K or so synth+notedata?
Photon is offline  
Old 15 January 2012, 01:58   #10
StingRay
move.l #$c0ff33,throat
 
StingRay's Avatar
 
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
Quote:
Originally Posted by Photon View Post
And 15MB+ precalced music instead of 1.5K or so synth+notedata?
Yes, because samples can be calculated in realtime (while CPU heavy effects run) because the 68k is so incredibly fast. This is Amiga so you have to make compromises and precalculating sample data is perfectly fine. Code something like this yourself before complaining about the memory requirements.
StingRay is offline  
Old 15 January 2012, 21:57   #11
mc6809e
Registered User
 
Join Date: Jan 2012
Location: USA
Posts: 373
Compare a bignum ( > 64-bit ints) library written in C with the same routines written in assembly. In C, carries must be inferred. In assembly, one has access to the carry bit.
mc6809e is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
VICE 64 How to usage? Amiten support.Apps 4 29 November 2012 19:26
[REQ:ASM] Assembling and running jman Coders. Tutorials 9 07 May 2011 18:39
WinUAE 1.0 Sampleripper Usage falconfx support.WinUAE 5 10 November 2006 09:11
Usage Suggestions fiath project.WHDLoad 4 05 October 2004 15:49
Heavy cpu usage - again abelthorne support.WinUAE 5 03 March 2004 11:32

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 16:03.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.08598 seconds with 13 queries