Welcome, Guest. Please login or register.

Author Topic: Verification of all system calls() ?  (Read 2072 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline freqmaxTopic starter

  • Hero Member
  • *****
  • Join Date: Mar 2006
  • Posts: 2179
    • Show only replies by freqmax
Verification of all system calls() ?
« on: April 04, 2011, 10:37:48 PM »
Is there any existing software to verify the correct functionality of the kickstart ROMs and libraries? ie that calls to them will actually produce the correct output.

Can be kind of useful for AROS m68k ROMs. (distfiles/aros-amiga-m68k-rom.bin)
For starters focus could be on the essential calls.
« Last Edit: April 05, 2011, 12:51:36 AM by freqmax »
 

Offline Piru

  • \' union select name,pwd--
  • Hero Member
  • *****
  • Join Date: Aug 2002
  • Posts: 6946
    • Show only replies by Piru
    • http://www.iki.fi/sintonen/
Re: Verification of all system calls() ?
« Reply #1 on: April 04, 2011, 11:08:43 PM »
Quote from: freqmax;627988
Is there any existing software to verify the correct functionality of the kickstart ROMs and libraries? ie that calls to them will actually produce the correct output.
No

Such verification will be huge pain in the behind, too. There are tons of functions that are very rarely used, and in some cases no viable example code exist at all.

Good luck.
 

Offline Karlos

  • Sockologist
  • Global Moderator
  • Hero Member
  • *****
  • Join Date: Nov 2002
  • Posts: 16879
  • Country: gb
  • Thanked: 5 times
    • Show only replies by Karlos
Re: Verification of all system calls() ?
« Reply #2 on: April 04, 2011, 11:17:29 PM »
What you are asking for is a suite of unit tests for the system libraries. Speaking as someone that has to write unit tests for production code on a regular basis, such a task would be very non-trivial.

Application-level unit tests aren't so difficult to manage since it's fairly easy to spoof data structures, add shims and other mechanisms to fake the environment the code that is being tested will be expected to run in and automate the verification of calls to a given piece of code.

Although the same principles would apply, doing the same things for operating system internals is rather more difficult, especially when you have to potentially deal with multiple threads, changes in privilege (not that a lot runs supervisor in AmigaOS) and whatever potential system-wide side effects of whatever the call you are trying to test hhas.
int p; // A
 

Offline freqmaxTopic starter

  • Hero Member
  • *****
  • Join Date: Mar 2006
  • Posts: 2179
    • Show only replies by freqmax
Re: Verification of all system calls() ?
« Reply #3 on: April 05, 2011, 12:46:47 AM »
If the scope is narrowed to application level test. And in particular the calls mostly used. So things like loading a sector from hard-disc actually returns 512 bytes and not 511 bytes or open a window with intuition actually does so etc..
I don't think automated test for OS internals will be needed. Though it doesn't hurt. Not many Amiga CPUs does threads nor does the OS implement privileges.
 

Offline vidarh

  • Sr. Member
  • ****
  • Join Date: Feb 2010
  • Posts: 409
    • Show only replies by vidarh
Re: Verification of all system calls() ?
« Reply #4 on: April 05, 2011, 07:14:05 AM »
Nothing existing. Get started!

Seriously, I've been compiling various small test cases for the console handler and device because I was (and still am when I get a few precious spare moments, which isn't often at the moment) working on the AROS console code and it behaves differently from the AmigaOS one in quite a few ways still.

I'd love seeing other people adding coverage for other parts, and perhaps jointly start assembling a proper set of unit tests that can run on at least classic AmigaOS and AROS...