Using "register" is virtually pointless these days because those good folks that write compilers already have tons of optimizations that are working in your favor. I'm sure that someone who has a more intimate relationship with compilers can flesh that out a bit for you.
If you've never explored templates at all, this might be a good example to implement (I think that's what arkoenig was getting at, but I don't want to speak for him). I believe the STL uses a quicksort, so if you have a debugger that lets you step into the library code, you can take a look at it in action.
jonsca
Quantitative Phrenologist
5,621 posts since Sep 2009
Reputation Points: 1,165
Solved Threads: 581
>> I want to get some feedback on my code to facilitate improvement.
Drop the array_begin and array_end pointer stuff. Use the [] operator instead on the passed in array. As pointed out, forget about register keyword. BubbleSort is slow already so drop the early exit boolean stuff and just simplify it all. That way you have at least something thats readable and just as slow-ish.
firstPerson
Senior Poster
3,923 posts since Dec 2008
Reputation Points: 841
Solved Threads: 608