Trying to improve x49gp
08-23-2018, 05:44 PM
Post: #29
 3298 Member Posts: 117 Joined: Oct 2014
RE: Trying to improve x49gp
3 months - I got sidetracked, obviously ...
But I do have a few fixes for x49gp in store, and I want to get them out there. Originally I wanted to push them out together with a proper QEMU update, but it looks like I've failed completing that for the second time, so I'll have to settle for the duct tape.

Let's get started with the easy stuff.
Code:
Fix some silly but fortunately inconsequential mistakes in recently added comments and similarly recently changed Makefile recipes
Well, "recently" relative to the average commit time spacing in x49gp. And don't ask how I managed to fail at dragging my finger across the top row of my keyboard to type "QUERTY" and "QUERTZ" instead of "QWERTY" and "QWERTZ".
The Makefile part was caused by me having a target for \$(TARGET).man.gz - seeing many such compressed man-pages in my system directories, I tried to mirror them and install a compressed version of the man-page. I later saw that other projects don't do that; it's the package manager compressing them for me. As a result, I deleted the rule for compression out of the Makefile, did a find-and-replace from ".gz" to "" to update the install targets - and forgot about the distclean targets (which were affected by the find-and-replace operation too). No big deal though, removing something twice doesn't hurt anyone when failures due to missing files are ignored anyway, so it all worked just fine. Removing the repetition merely makes the Makefile cleaner.

Code:
Remove the option to build with QEMU 0.9.0, it was very broken anyway 0.12.50 is not much better, but at least it's ancient instead of stone-age, and it compiles without jumping through ridiculous hoops.
Warning: big patch for this one due to a large number (and large total size) of deleted text files.

Code:
Update gdbstub to the appropriate QEMU 0.12.50 revision It was a heavily modified copy from 0.9.0 before, with slight changes to make it work with 0.12.50 when that update came to x49gp. Now it's still heavily modified, but at least it has the fixes that were applied to the original between these QEMU revisions, including a fix for the rare remaining cases of single-step walking into an interrupt.
This is one of the two main reasons I didn't want to hold these patches back any longer (see the post just before this one). Claudio, your debugger fix is finally here.

Code:
Fix some warnings in block-*.c which caused compilation failures via -Werror These are basically (back-)ports of the fixes standard QEMU received in commits 2dedf83e, 3e1a8134, 1e37d059, just without the qemu_write_full part in the second one because we don't have that.
When I can't do a proper upgrade, the duct-tape that is a (back-)port of the crucial fixes will have to do. This is the other reason for getting this out; shortly after the last post a compiler / system header update caused a compilation error via a warning and -Werror on my setup. (Something about stringop and truncation, I don't remember the exact message.) For some weird reason it vanishes when compiled with _FORTIFY_SOURCE, but that makes the warnings Claudio got appear instead (they are all in the block-*.c files). I've chosen to add _FORTIFY_SOURCE to the Makefile and to (back-)port the QEMU fixes that get the other warnings out of the way.
You might wonder why I wrote "(back-)port" instead of "backport". One of the three QEMU commits mentioned in my commit message is actually older than the version 0.12.50 used in x49gp, which makes this technically not a backport - but similar to the gdbstub.* files the block-*.c files have been copied out of 0.9.0 for heavy modification and were lightly touched up in the 0.12.50 update, so this fix was not present in the modified files. Updating the gdbstub part is done now, but the block drivers seem to be more stubborn - in the gdbstub update I was able to dodge the references to stuff that's stripped out of our QEMU 0.12.50 version by picking bits for system-level and user-level emulation as needed (just like it was originally done in the 0.9.0 version), but it looks like the block drivers won't let me get away so easily. And I believe getting every QEMU part in x49gp to the same version first is the best path towards a QEMU update, sooo ... that's the spot where I failed this time.

If someone else wants to look into this QEMU update mess (or if I manage to forget this info and need to look it up somewhere), you'll probably want to know what revision this version 0.12.50 actually refers to. It's somewhere between git commits 576c2cdc (from Jan 15, 2010) and baee019f (from Jan 19, 2010), both inclusive. The files touched inbetween are all stripped out, so getting more precise than that is both impossible and pointless. The old 0.9.0 version used to be shipped with x49gp as a ZIP archive extracted and patched at build time, until I ditched it as part of the second patch in this post (with Git being a distributed version control system the history suffices as a backup); it's also simply the release_0_9_0 tag, as far as I know.

The patches are attached, as usual.

Attached File(s)
25+26+27+28.zip (Size: 52.07 KB / Downloads: 6)
 « Next Oldest | Next Newest »

 Messages In This Thread Trying to improve x49gp - 3298 - 10-28-2014, 10:08 PM RE: Trying to improve x49gp - Han - 10-28-2014, 10:53 PM RE: Trying to improve x49gp - Egan Ford - 10-29-2014, 02:54 AM RE: Trying to improve x49gp - Egan Ford - 10-29-2014, 02:57 AM RE: Trying to improve x49gp - Egan Ford - 10-29-2014, 03:10 AM RE: Trying to improve x49gp - 3298 - 10-29-2014, 08:43 AM RE: Trying to improve x49gp - Egan Ford - 10-31-2014, 12:36 AM RE: Trying to improve x49gp - debrouxl - 10-29-2014, 09:18 AM RE: Trying to improve x49gp - Claudio L. - 10-29-2014, 11:58 AM RE: Trying to improve x49gp - Claudio L. - 10-29-2014, 12:04 PM RE: Trying to improve x49gp - Anderson Costa - 11-03-2014, 07:17 PM RE: Trying to improve x49gp - 3298 - 11-04-2014, 09:50 PM RE: Trying to improve x49gp - Egan Ford - 11-08-2014, 09:50 PM RE: Trying to improve x49gp - 3298 - 05-05-2018, 10:43 PM RE: Trying to improve x49gp - 3298 - 05-05-2018, 10:45 PM RE: Trying to improve x49gp - Claudio L. - 05-07-2018, 06:33 PM RE: Trying to improve x49gp - 3298 - 05-07-2018, 08:55 PM RE: Trying to improve x49gp - Claudio L. - 05-07-2018, 11:09 PM RE: Trying to improve x49gp - dmmaster - 05-07-2018, 07:17 PM RE: Trying to improve x49gp - 3298 - 05-07-2018, 08:12 PM RE: Trying to improve x49gp - dmmaster - 05-07-2018, 08:36 PM RE: Trying to improve x49gp - Claudio L. - 05-08-2018, 02:57 AM RE: Trying to improve x49gp - 3298 - 05-08-2018, 11:19 AM RE: Trying to improve x49gp - Claudio L. - 05-08-2018, 03:02 PM RE: Trying to improve x49gp - 3298 - 05-08-2018, 06:17 PM RE: Trying to improve x49gp - 3298 - 05-13-2018, 10:27 PM RE: Trying to improve x49gp - Claudio L. - 05-14-2018, 01:24 AM RE: Trying to improve x49gp - 3298 - 05-15-2018, 10:22 AM RE: Trying to improve x49gp - 3298 - 08-23-2018 05:44 PM RE: Trying to improve x49gp - ijabbott - 08-23-2018, 07:15 PM RE: Trying to improve x49gp - Claudio L. - 08-24-2018, 02:36 AM RE: Trying to improve x49gp - 3298 - 08-26-2018, 02:22 PM RE: Trying to improve x49gp - pier4r - 08-26-2018, 06:31 PM RE: Trying to improve x49gp - Claudio L. - 08-27-2018, 01:39 PM RE: Trying to improve x49gp - 3298 - 08-27-2018, 08:20 PM RE: Trying to improve x49gp - Claudio L. - 08-27-2018, 09:07 PM RE: Trying to improve x49gp - 3298 - 08-27-2018, 10:39 PM RE: Trying to improve x49gp - Claudio L. - 08-28-2018, 02:51 AM RE: Trying to improve x49gp - 3298 - 08-28-2018, 08:04 AM RE: Trying to improve x49gp - Claudio L. - 08-29-2018, 02:17 AM RE: Trying to improve x49gp - 3298 - 08-29-2018, 11:12 AM RE: Trying to improve x49gp - Claudio L. - 08-29-2018, 10:02 PM RE: Trying to improve x49gp - 3298 - 08-29-2018, 10:21 PM RE: Trying to improve x49gp - brickviking - 08-29-2018, 10:46 PM RE: Trying to improve x49gp - 3298 - 08-29-2018, 11:53 PM RE: Trying to improve x49gp - Claudio L. - 08-30-2018, 09:35 PM RE: Trying to improve x49gp - Claudio L. - 08-29-2018, 10:09 PM RE: Trying to improve x49gp - brickviking - 08-31-2018, 12:10 AM RE: Trying to improve x49gp - Claudio L. - 08-31-2018, 12:47 AM RE: Trying to improve x49gp - 3298 - 08-31-2018, 08:15 AM RE: Trying to improve x49gp - Claudio L. - 08-31-2018, 06:11 PM RE: Trying to improve x49gp - pier4r - 08-31-2018, 07:43 PM RE: Trying to improve x49gp - brickviking - 08-31-2018, 10:52 PM RE: Trying to improve x49gp - Sylvain Cote - 08-31-2018, 11:12 PM RE: Trying to improve x49gp - Claudio L. - 08-31-2018, 11:45 PM RE: Trying to improve x49gp - Claudio L. - 10-04-2018, 09:21 PM RE: Trying to improve x49gp - brickviking - 10-05-2018, 08:55 AM RE: Trying to improve x49gp - 3298 - 10-05-2018, 11:26 AM RE: Trying to improve x49gp - 3298 - 10-09-2018, 03:13 PM RE: Trying to improve x49gp - Claudio L. - 10-10-2018, 02:25 PM RE: Trying to improve x49gp - 3298 - 10-10-2018, 09:50 PM RE: Trying to improve x49gp - Claudio L. - 10-11-2018, 02:43 AM RE: Trying to improve x49gp - Claudio L. - 10-05-2018, 06:33 PM RE: Trying to improve x49gp - brickviking - 10-05-2018, 09:43 PM RE: Trying to improve x49gp - brickviking - 10-10-2018, 09:21 PM

User(s) browsing this thread: 1 Guest(s)