RABiD BUNNY FEVER
Languages and Libraries
Contains a list of all of my commonly used languages and libraries.
Other language information:
- ASM (x86 Assembly): This is the lowest level [low level] (closest to computer machine code) human readable computer language that exists. The code that you write is the actual instructions (called opcodes) given to the CPU. When writing in assembly, you only have a few intermediate ‘variables’ to work with, called registers, and a stack that you can push and pop variables from. You can also only write one very simple line of code at a time, so things (like math functions) aren’t easily readable.
Click here to toggle more information
would be written as
|IDIV c||//a=a/c *|
*There are many caveats to assembly instructions, like only the A variable can be used as the dividend in division.
This makes assembly a less than optimal language to use for programming unless you are coding for speed, as higher level [high level
] languages can never be truly as fast or small as properly hand coded assembly.
Assembly has one more major drawback, in that it doesn’t ‘scale’ with new technology. In this, I mean that all processors are faster at certain things, and slower at others, so output varies depending on which type of CPU
a higher level [high level
] piece of code is compiled for. For example, on older CPU
s, the shift register (which multiples numbers by powers of 2) was extremely fast, unlike the slow ‘multiplier’ command, so it was faster to compile
x*9 as x*8+x (8 is 2^3)
for older CPU
Then there are even more tricks beyond this, for example
x*7 = x+x*2+x*4
would be compiled for older CPU
|ADD b,b||//b=b+b - b=(a*2)|
|ADD a,b||//a=a+b - a=(a*3)|
|ADD b,b||//b=b+b - b=(a*4)|
|ADD a,b||//a=a+b - a=(a*7)|
One of my favorite assembly tricks is variable swapping. I’m not going into the math behind this, but it’s a neat trick.
Instead of using a temporary variable to swap 2 variables (a and b) like....
You just xor them back and forth
Long story short. Assembly is only for uber
programming geeks like me that like to get down in the dirt and hard code things for speed.
For compiling, to put things in simplified manner, each assembly code (including type of following variables) is really just an 8 or 16 bit
value known by the CPU
, and then accessed variables come after it.
(These examples might not be entirely accurate.)
For example, ADD a,8 would output directly to the CPU
and ADD b,a would output directly to the CPU
The Intel assembly software developer’s manuals are freely available online. They detail all one would need to know to program in assembly, and the basics of CPUs and their design. They are excellent references.
You can download the older digital copies I acquired in early 2004 here:
Too bad Intel will no longer ship out hard copies of these books for free. I ordered one of, if not the very last, sets of these books right before Intel discontinued the free online offer ^_^;.
- C: A simple name for the simple yet powerful language. C is the predecessor to C++, and is the next closest language to the CPU. It is my language of choice (well.. C99 is... see the more info section in C++ for more of an explanation) as it is super fast and efficient, robust, powerful, and customizable. C lets you control ever aspect of your code to precise standards, and you know exactly how it’s going to compile and interact with the CPU. I sometimes mark programs as C that are technically C++. This just means it’s C99 and doesn’t include higher level C++ members like templating and classes (though it may also includes new/delete operators and cin/cout, which really just translate into alloc/free & printf/fread).
- C++: The child of C, created/developed by Bjarne Stroustrup, has many advantages and disadvantages over C. It adds higher level [high level] functionality to the language which, if not utilized properly, can seriously impact programming performance, in not only speed, but maintainability and other aspects.
All C/C++ releases are (currently) formatted for and compiled in Visual C++ 6.0 (MSVC6), which has 4 spaces per tab.
If running Visual Studio 6.0, don’t forget to install the Service packs in the following order: Service Pack 5, Service Pack 6, [SP6 to PP patch], Processor Pack
I also recommend Visual Assist X for a nicer UI experience.
Click here to toggle more information
Many additions included in C++ also including in C99 that I utilize are:
- inline functions
- Variable declaration anywhere within functions
- “bool” type
- one line comments with “//”
- improved support for IEEE floating point
C99 also has variadic macros, which I’ve always wished C++ did :-\.
I use classes whenever appropriate, very often with many inline functions for its simpler operations.
But it’s when you start getting into polymorphism, inheritance, and virtual functions when things start getting... messy, and no longer very optimized. Even normal C++ classes hide things from the user. The “thiscall” class function calls basically just pass the pointer to the class structure as the first variable, which is why you can’t take function pointers of class functions, just “Pointer to member” (.* ->*) operators for something like it.
- C#: See VB.NET. The “Predecessor” to C# is C++, though there are a lot more differences between the 2 than there are between VB6 and VB.NET.
- VB4/VB6: Good ’ol visual basic. It has “basic” in its name for a reason. It’s not meant for true programmers doing real programs. It has the ease of use, but not the flexibility or speed. I still find it useful every now and then to throw together quick GUI apps when I don’t feel like dealing with C. You can still do anything in it that you can do in other languages; just not as elegantly. It also has the major drop in speed, as any interpreted languages do.
You will need the VB language runtimes to run visual basic programs.
- VB.NET: Like all .NET languages, VB.NET is pretty much the same as its predecessors (in this case, Visual Basic) by look and feel alone. The only major differences are the available libraries, which of course are now all the .NET libraries, and that they compile down into the CLR (Common Language Runtime) byte code, meaning .NET is interpreted, so all the .NET languages are interchangeable and play well together.
All .NET applications require the .NET framework be installed on your computer. These are provided as automatic updates for all modern Windows operating systems, so you probably have them.
- VBA: VBA is simply VB for Microsoft [Office] Applications. It really doesn’t different from actual visual basic much, if at all.
- Java: Originally developed by Sun Microsystems, and recently made open source, very quickly caught on as a primary computer development language after its conception. It is an interpreted language and rather slow, even compared against .NET. I personally hate JAVA for multiple reasons including its sluggishness due to its less than optimal garbage collection, the fact that it only encodes and does not compile to byte code, and that many colleges teach only it so students become reliant on it and completely worthless.
The one thing I do like about Java is that it is can be used to implement the most powerful web applets, as it is more robust than Flash. But even this comes at a price, in that most people do not have Java installed to run in their web pages, nor do they have reason too.
- PHP: PHP is, in my opinion, the most suited language for standard server side web page programming. It is a successor to Perl, and has a very very useful base library set, is very simplistic and quick as a scripting language, and is easy to debug.
Click here to toggle more information
Its downsides are:
- It is interpreted
- Separate instances are ran for each web page load, so can be a bit tricky remembering data between sessions
- It has no garbage collection. Its only real memory management is that local variables are deleted on function exit. Though this actually isn’t necessarily a bad thing, as memory management is time consuming, and all memory is dropped immediately on the end of the run instance. This only really becomes a problem when you try to use PHP for large memory processes that take a long time to run (like mass email sends.)
- Perl: Perl is the predecessor of many languages, including PHP. It is interpreted, and can be run from either a compiled byte code format, or straight from its original source. This makes it very useful for enterprise applications that do not rely on speed and may need to be worked on and edited far into the future by many people. Perl has a VERY large repository of ‘official’ libraries to help speed along development. It’s great for quickly scripting together projects that mainly rely on text manipulation.
- Python: Python is a bit different in that it is an interpreted language, but it is not dynamic in nature (no eval statement), and it is [dynamically] typed. It’s great for large projects that aren’t time critical due to its quickness in developing and typed nature making it easier to debug. See Python Pros and Cons for more information.
GoLang (Google’s Go):
This language fills a nice niche between compiled and interpreted languages. While it is compiled, so code runs very fast, it has support for a lot of features needed in a modern language that C++ just does not fill. This includes:
The language also forces the programmer to adhere to a very strict set of syntax [and other] rules, which allows programs to compile SUPER fast, but also removes a ton of flexibility. Quite frankly, my experiences with the language so far have been very jaded due to this strictness.
- Strong and natural string and Unicode support
- Strong concurrency and threading features
- Garbage collection (which may or may not be a hindrance depending on your goals)
- QBasic: Also known as QuickBasic, this was the first language I ever wrote in, and is very, very, very old. It is the successor of BASIC, whose main difference was that you had to write line numbers in front of every statement. QBasic programs are ran straight from their code in the editor environment (straight off the Win98 CD), though a pre-internet-elusive compiler does exist.
- Direct3D (D3D): Microsoft’s 3D library and interface to GPUs (Graphical Processing Units). Only available for Windows. This is one of the parts of DirectX.
Direct3D requires that you have DirectX installed.
- OpenGL: The open source 3D library and interface to GPUs.
- GPU ASM: Assembly language for GPUs. These are the low level way to right 3D shaders for the pixel, vertex, or geometry pipelines.
- MySQL: The most widely utilized open source database solution (recently bought out by Sun). SQL is a [scripted] computer language used for querying information from databases.
- MSSQL: Microsoft’s implementation of SQL... it’s rather quirky.