News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

HLA stdlib v2.4 is now available

Started by Randall Hyde, October 12, 2007, 08:30:29 PM

Previous topic - Next topic

Randall Hyde

Hi All,

The HLA Standard Library, v2.4 is now available on Webster.
You can download a copy from the stdlib v2.x support page:


http://webster.cs.ucr.edu/AsmTools/HLA/stdlib2/index.html


v2.4 of the HLA stdlib includes documentation for several
modules that were previously undocumented.


The HLA standard library includes over 1,000 functions and macros
callable from assembly language programs.  Combined with the test
suite, the entire library represents nearly 400,000 lines of assembly
code.  Compressed, the library module consumes 4.6 MB, it expands to
over 23 MB of source code and test data (not including object and
library files).


One of the principal benefits of the v2.x standard library over the
older 1.x library is the new automated regression test suite. This
code automatically checks the operation of just about every function
in the standard library using a wide range of input values (some
functions only a few checks, some functions get as many as a billion
checks -- it all depends on the semantics of the function).


The HLA stdlib v2.x has been completely refactored/rewritten from v1.x
over the past year. This refactoring has resulted in more efficient
(faster) code as well as code that is much more stable.  100s of
defects have been eradicated from the old code. Furthermore, the
semantics of the functions across multiple OSes has been *greatly*
enhanced. With this release, about the only difference you'll find
between applications written for Linux versus Windows is the end-of-
line character that is written to files. 


The HLA stdlib v2.x also includes an automated build generator that
will automatically generate a set of make files for the library code
(including any new functions the user might want to add). This
"mkmake" program recursively determines all the dependencies in the
HLA and HHF files and creates appropriate make files for Windows or
Linux/*NIX. This eliminates a lot of maintenance headaches for someone
who is working on the library, especially for newcomers to the project
who might otherwise feel overwhelmed by the magnitude of the project.


Another advantage to the new code is that it is almost completely
written in "pure" assembly language, so it can serve as an advanced
assembly language educational tool (the code is not suitable for
beginners as much of it is a bit too advanced for them, but it's great
code for someone to look at as they begin to gain some experience with
assembly language).



The library itself is currently organized into the following modules:


args -- command-line argument manipulation.
arrays -- array manipulation
bits -- bit manipulation
chars  -- character routines and predicates
conv  -- conversion functions
cset -- character set operations
datetime -- date and time calculations
fileclass -- object-oriented file operations
fileio -- file operations.
lists -- object-oriented list operations
math -- extended precision integer operations and floating-point
functions
memory -- memory allocation and deallocation.
os_console -- console app display manipulation
os_coroutines -- coroutine support
os_dependent  -- miscellaneous OS dependent functions.
os_env -- environment variable support
os_excepts -- exception handling support
os_fileio -- file I/O functions (platform-dependent code)
os_filesys -- file system operations (platform-dependent code)
os_linux -- Linux support functions
os_memmap -- Memory-mapped file support code.
os_timer -- code timing support
os_windows -- Windows support functions
patterns -- pattern matching library
random -- random number generators
stderr -- output to the standard error device
stdin  -- input from the standard input device
stdout  -- output to the standard output device
strings -- character string functions
zstrings -- zstring functions.


Over the years, the HLA standard library has been, without question,
the favorite component of the HLA system by HLA users. This new
library will certainly carry on that tradition.


Ultimately, the goal is to get this project completely supported on
SourceForge (there's actually a page there already, but it only
contains the compressed files; eventually the plan is to use the
source-code control facilities of Source Forge for world-wide
developer access to individual functions).  The HLA standard library
is current maintained on the Subversion source code control system,
which will mesh quite well with SourceForge.


Enjoy!
Randy Hyde



stevenp

Quote from: Randall Hyde on October 12, 2007, 08:30:29 PM
Another advantage to the new code is that it is almost completely
written in "pure" assembly language...

Does this mean that HLA is not as powerful as "pure assembly"?  If so, why would that be?

Sevag.K

He means it's written in low(er) level assembly than the current stdlib.  HLA is powerful enough to handle both coding styles.

stevenp

Quote from: Sevag.K on October 27, 2007, 03:26:42 AM
He means it's written in low(er) level assembly than the current stdlib.  HLA is powerful enough to handle both coding styles.


Thanks.  That's what I was hoping.

Randall Hyde

Quote from: stevenp on October 25, 2007, 07:26:33 PM
Quote from: Randall Hyde on October 12, 2007, 08:30:29 PM
Another advantage to the new code is that it is almost completely
written in "pure" assembly language...

Does this mean that HLA is not as powerful as "pure assembly"?  If so, why would that be?

In many respects, "pure assembly" is actually less expressive that "high-level assembly". So, arguably, this is a step backwards for the library. It is certainly less readable and unquestionably more difficult to debug the "pure assembly code" (having had to test this code, I can assure you that I discovered lots of new bugs when I rewrote the code in low-level assembly).

However, I've always promoted the Standard Library source code as an educational product -- something that contains lots of assembly source code that people could look at and learn from. It was pointed out to me that (with the older, v1.x version of the library) I was not really living up to my claims as the stdlib code contained lots of high-level code and if I wanted to claim it as an educational tool I should use low-level code as much as possible. I couldn't argue with that, so I made the conversion when creating HLA stdlib v2.x.  There *are* some efficiency benefits to using the low-level code, but they are relatively minor.
hLater,
Randy Hyde

stevenp

I understand the point of it being an educational tool but I see no reason why HLA can't stand on its own as a viable means of software development where assembly fits the bill.  The combination of the two (high level portions and low level assembly) just simply make for more useful and productive development than a low level assembly alone.

BTW, I only finally got your books.  I bought all three (got tired of waiting for my boss to get the HLA book) and I am going through the HLA and How To Write Great Code Vol. 2 simultaneously (I'll do Vol 1 later since I know the number systems already). Before I got them I was going through Assembly Language Step by Step (the old 16-bit book).  The author (sorry, don't know his name off the top of my head, but you know the book) is very good at explaining assembly.  Of course, being 16 bit he had to explain segmentation, etc. which isn't needed in 32 bit, but still it is a good very beginners level book.  Perhaps you two should team up. :)  That would be one awesome team to develop an assembly language book. :)

Oh, and a neat educational tool for learning assembly is emu8086 (www.emu8086.com).  Too bad there wasn't a 32 bit version of this.

Kind Regards,
Steven