Previous Thread
Next Thread
Print Thread
Page 5 of 9 1 2 3 4 5 6 7 8 9
Re: Arm Akimbo SDLMAME [Re: R. Belmont] #57344 12/27/09 03:40 PM
Joined: Jul 2006
Posts: 87
L
ldesnogu Offline
Member
Offline
Member
L
Joined: Jul 2006
Posts: 87
I got the SDK installed using this page: http://www.niemueller.de/blog/id/234.
It seems to work, though I don't know what to do next. What I probably need is some trivial example to compile. More time to spend reading doc I guess smile
The last time I tried to install Maemo on CentOS 5.x, I got a coredump from Xephyr. It looks like this was fixed.

Re: Arm Akimbo SDLMAME [Re: ldesnogu] #57446 01/01/10 09:24 AM
Joined: Jul 2006
Posts: 87
L
ldesnogu Offline
Member
Offline
Member
L
Joined: Jul 2006
Posts: 87
I could reproduce Flandry Illegal instruction error.

gdb tells me the error happens @0x0072f37c
Code:
(gdb) disassemble 0x72f370 0x72f37f
Dump of assembler code from 0x72f370 to 0x72f37f:
0x0072f370 <floor+7473708>:	mov	r0, r4
0x0072f374 <floor+7473712>:	bl	0x6fcaec <floor+7266728>
0x0072f378 <floor+7473716>:	vldr	s15, [r6, #52]
0x0072f37c <floor+7473720>:	vcmp.f32	s15, #0.0
(gdb) info registers r6
r6             0x500b237	83931703

Looks bad, 0x0072f378 is doing an unaligned load... But the kernel is configured to fix that up, and the memory @r6 is accessible.

Also as far as I know the vcmp instruction is valid.

To sum up I don't know what the issue is frown

I'll rebuild with symbols.

EDIT: I forgot to say that the executable runs fine on the QEMU ARM provided with the SDK. No big surprise, QEMU isn't that accurate smile

EDIT 2: I found the issue. Even though the kernel should fixup alignment issues, it fails to recognize the vldr instruction as a load instruction. So MAME will have to be fixed not to generate such loads smile
For info the offending line is 1029 in sdlmame0136/src/emu/video.c.

Last edited by ldesnogu; 01/01/10 10:37 AM.
Re: Arm Akimbo SDLMAME [Re: ldesnogu] #57450 01/01/10 11:19 AM
Joined: Jul 2006
Posts: 87
L
ldesnogu Offline
Member
Offline
Member
L
Joined: Jul 2006
Posts: 87
The problem seems to be solved.

The issue is that the inline_config field of _device_config is starting with a tag which length isn't necessarily a multiple of 4 and hence the data used isn't aligned.

Something like this:
Code:
--- src/emu/devintrf.c~	2010-01-01 07:20:48.000000000 +0100
+++ src/emu/devintrf.c	2010-01-01 12:17:08.771259165 +0100
@@ -134,6 +134,7 @@
 	device_config *device, *tempdevice;
 	tagmap_error tmerr;
 	UINT32 configlen;
+	UINT32 additionalalign;
 
 	assert(devlist != NULL);
 	assert(devlist->map != NULL);
@@ -146,8 +147,11 @@
 	/* get the size of the inline config */
 	configlen = (UINT32)devtype_get_info_int(type, DEVINFO_INT_INLINE_CONFIG_BYTES);
 
+	/* add some room to make sure the device structure is aligned to a multiple of 4 */
+	additionalalign = (4 - (strlen(tag) + 1)) & 3;
+
 	/* allocate a new device */
-	device = (device_config *)alloc_array_or_die(UINT8, sizeof(*device) + strlen(tag) + configlen);
+	device = (device_config *)alloc_array_or_die(UINT8, sizeof(*device) + strlen(tag) + configlen + additionalalign);
 
 	/* add to the map */
 	tmerr = tagmap_add_unique_hash(devlist->map, tag, device, FALSE);
@@ -180,7 +184,7 @@
 		device->clock = device->owner->clock * ((device->clock >> 12) & 0xfff) / ((device->clock >> 0) & 0xfff);
 	}
 	device->static_config = NULL;
-	device->inline_config = (configlen == 0) ? NULL : (device->tag + strlen(tag) + 1);
+	device->inline_config = (configlen == 0) ? NULL : (device->tag + strlen(tag) + 1 + additionalalign);
 
 	/* ensure live fields are all cleared */
 	device->machine = NULL;


Now I need to understand why SDL doesn't accept the keyboard return key, but given how lazy^Wbusy I am, I will perhaps leave that to someone else smile

Re: Arm Akimbo SDLMAME [Re: ldesnogu] #57473 01/02/10 06:51 AM
Joined: Dec 2009
Posts: 24
F
Flandry Offline OP
Member
OP Offline
Member
F
Joined: Dec 2009
Posts: 24
Thanks for tracking that down. I haven't used gdb for years and then only briefly and was having trouble getting it working, or rather getting an armel binary with symbols. Anyway plenty more time to play with that ahead i think...

The keymap issue was easy to resolve. I get
Average speed: 34.46% (84 seconds) in Ghosts and Goblins, autosave worked.
Average speed: 26.54% (77 seconds) in SF2

Sound is not really good but it's a start. Unfortunately the Fn key doesn't work as a key map but otherwise the control options seem pretty complete.

I'll grab the new version and put up the patched package.

Re: Arm Akimbo SDLMAME [Re: Flandry] #57686 01/07/10 08:11 PM
Joined: Mar 2001
Posts: 16,390
R
R. Belmont Offline
Very Senior Member
Offline
Very Senior Member
R
Joined: Mar 2001
Posts: 16,390
Pandora's just been delayed again, but I'll be looking at ARM SDLMAME either way hopefully soonish since Palm just announced a native C/C++ SDK with SDL (!) and OpenGL for WebOS phones, and I have a Pre.

Last edited by R. Belmont; 01/07/10 08:27 PM.
Re: Arm Akimbo SDLMAME [Re: R. Belmont] #57693 01/07/10 10:27 PM
Joined: Jul 2006
Posts: 87
L
ldesnogu Offline
Member
Offline
Member
L
Joined: Jul 2006
Posts: 87
OMAP3 has been obsoleted by Tegra2 :-)

Re: Arm Akimbo SDLMAME [Re: ldesnogu] #57694 01/07/10 10:37 PM
Joined: Mar 2001
Posts: 16,390
R
R. Belmont Offline
Very Senior Member
Offline
Very Senior Member
R
Joined: Mar 2001
Posts: 16,390
Sure, if you can figure out some way to get a shell prompt in an Audi ;-)

Re: Arm Akimbo SDLMAME [Re: R. Belmont] #57749 01/08/10 10:51 PM
Joined: Jul 2006
Posts: 87
L
ldesnogu Offline
Member
Offline
Member
L
Joined: Jul 2006
Posts: 87
No need for that wink

BTW nVidia T2 dev board is available and costs $400.

Last edited by ldesnogu; 01/08/10 10:53 PM.
Re: Arm Akimbo SDLMAME [Re: ldesnogu] #57750 01/08/10 11:04 PM
Joined: Mar 2001
Posts: 16,390
R
R. Belmont Offline
Very Senior Member
Offline
Very Senior Member
R
Joined: Mar 2001
Posts: 16,390
Can random people order it? Otherwise I'll wait for the inevitable OMAP4 version of the BeagleBoard =)

Re: Arm Akimbo SDLMAME [Re: R. Belmont] #57751 01/08/10 11:23 PM
Joined: Jul 2006
Posts: 87
L
ldesnogu Offline
Member
Offline
Member
L
Joined: Jul 2006
Posts: 87
As long as you live in the US or Canada you can order now. You need a project too and probably a company name.

http://tegradeveloper.nvidia.com/tegra/f...ch-does-it-cost
Quote:
Currently, you must apply for and be accepted as a registered NVIDIA developer. While we cannot guarantee that every application will be accepted, applications that thoroughly answer the questions in the registered developer application have a higher rate of acceptance. Applications with misleading or false information will be removed with no further review. If the questions require that you breach confidentiality, please contact tegradev@nvidia.com and request an NVIDIA representative contact your company as soon as possible.

The Tegra developer kits are currently priced at $399 and are currently only available in the US and Canada. We are working on making the developer kits internationally available where export laws allow, but we have no specific date yet.


EDIT: BTW the BeagleBoard OMAP4 will exist for sure, as I was told by the guy behind the project.

Last edited by ldesnogu; 01/08/10 11:24 PM.
Page 5 of 9 1 2 3 4 5 6 7 8 9

Moderated by  R. Belmont 

Who's Online Now
1 registered members (Pernod), 179 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
ShoutChat Box
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics8,722
Posts114,633
Members4,873
Most Online510
Aug 26th, 2019
Powered by UBB.threads™ PHP Forum Software 7.7.3