Assembly Languages

Status
Not open for further replies.

nitish_mythology

OSS Enthusiast!
Can u pls guide me abt assembly languag programming....

What is the diff between them and HLL?
Examples(Is perl too an assembly level language?)
There use in the present time.

Thnx...
 

nithinks

True Techie
assembly level languages are the basic for all programming languages that we
work with.
All softwares that we execute will ultimately in ASSEMBLY LEVEL only!
A.L.L consists a set of instructions, including register to register ,reg to memory ,and mem to reg instructions
typical A.L.L looks something like

assume CS code,DS data
MOV AX,DATA
MOV DS,AX
data ends
code segment
...
...
...
code ends

this program consists two segments DATA and CODE respy.
AX,BX,CX,DX are general purpose CPU registers(16bit or 32 bit)
DS etc are data segment stack segment is SS
suppose we want to add the contents of two registers,
ADD AX,BX
the result will be stored in BX
like this u have to write the entire program
even TC,TC++ etc are basically designed using assembly level lang
only.
 

ilugd

Beware of the innocent
do a search on google for "assembly language simple tutorial" and browse through the results. You will get quite a few of them.

However be warned that assembly language programming is not easy. And if you really want to learn programming, start with some other language, as assembly screws up your programming style. Try python, c++ or java instead.

Just my two cents!
 

gary4gar

GaurishSharma.com
in lay man words;
assembly language [edited]reason oops my bad! ! !
HLL uses comman words as systax and then a complier or interpretor converts them in binary code.hope its clear

regrads,
gary
 
Last edited:
OP
nitish_mythology

nitish_mythology

OSS Enthusiast!
I hv no intention to learn assembly level programming...
Two ques--
1.Is it used nowdays, if yes than whats its use?
2.Is perl an assembly level language?
 

puja399

In the zone
This is what I know:
1) Assembly language does not involve writing programs in Machine Code or Binary code. Assembler converts the assembly language code into object code, unlike other Middle/High level languages where the compiler converts the respective code into machine/object code. It is the Linker that converts the Object code into Machine code or Binary code. So, the opinion that Assemble language uses binary code to express the routine is not correct. HLL uses terms and syntaxes that are closer to english terms, and uses functions/procedures/libraries that hide the internal working of the code, and thus making the code more readable /reusable.

2) Interpreter does not convert anything, it just interprets the code line by line and executes it within its own virtual machine, like, VBScript, Perl etc. This is the basic difference between Assembler/Compiler and Interpreter, that is u cannot get the Object code from the Interpreter, and thus Native code cannot be obtained from it (excluding the situations where JIT compiler is available from within the VM).
3) Assembly language programming is still very much useful nowadays (even in this era of Java and .NET), especially if u write device drivers or want to reverse engineer anything. As a matter of fact, there are a group of people who use Win32 Assembly language to create very small, incredibly fast and useful freewares that also look nice. In fact, it is often said that a good part of the Windows OS itself is written in Assembly language. Assembly language programming is available in Linux platform also.

4) Perl is neither Assembler nor compiler, but only an Interpreter, but I already said that earlier.

5)Unlike popular beliefs, Win32 Asm Language is not that difficult (its certainly much easier than the 16-bit era), but it requires expert knowledge nevertheless. Its better to learn the basic programming capabilities (with C++ or Java) and then try Asm.
 

rohan

In the zone
It's better to go with C/C++. Java isn't a that good language. Java as I view it has been a failure. Perl and Python are also good languages and excellent if you plan to go towards linux development. Almost all distros today come with deticated Perl and Python support.
 

abhasbajpai

Asterisk enthusiast
java now days mostly used for mobile plateform or embeded platefporfms only
BTW could any one tell me a good sucessfull (comerssioly)standalone application devolped in JAVA and why any biggy (adode, IBM or any uses java in their application where as c++ is used everywhere)
 

JGuru

Wise Old Owl
Java is used widely on the Server-side. There are 5 million Java developers
worldwide. On the Mobile front it's gaining ground. Of late Java GUI applications are flooding
thanks to some performance improvements implemented by Sun.
Lot of fortune 500 companies like Oracle, HP, IBM , BEA, Oracle use Java.
JBoss is a very successful Web Server fully written in Java, now acquired by
RedHat. A company called Techdigm has developed an Office Suite fully in Java.
It's called Techdigm Office 2.1. It's fully compatible with MS Office.
Checkout the link for yourself:
*www.techdigm.com/product.jsp
Still not convinced, checkout Swing Sightings:
*java.sun.com/products/jfc/tsc/sightings/index.html
There are hundreds of GUI applications developed using Java.
 
Last edited:

dheeraj_kumar

Legen-wait for it-dary!
dont tell me you guys dont use LimeWire :)

win32 asm is not difficult, its just a little complicated. you just need to know about the processor, registers(high, low) and extended ones(EIP, EDI etc) also about interrupts. thats the basic in asm. its not like high level languages, but is the most simplest form of a code.
 

rohan

In the zone
abhasbajpai is right.. The Bytecode nature (compiled/interpreted) of Java applets is the main reason for problems. Any Java program is 10 to 20 times slower than it's C++ counterpart(if written optimally). Java hasn't been succesfull in complete utilization of the OS's API as has been C++. Java is definitely an easier language, but the programming language 'D' (*digitalmars.com/d) is equally simpler and compiles to executables. Java is used only on mobile platforms and for internal processes and servlets(which are also out of fashion now) but never for commercial applications.
 

abhasbajpai

Asterisk enthusiast
j guru agreed
but could tell me why the SUN has devloped its office suite (star office and open source open office.org)in c++ and not in JAVA that answers my question and do you have stats how many devlopers for c++ and related languges
and could tell me the market share of APATCHE and JBoss
BTW star office and open office.org are most popular office suite after MS Office
 
Last edited:

khansdream

Journeyman
Yes Puja399, you were explaining assembly lang. And i really appreciate the way you explained. I wanted to rep you but its disable presently by mods (ref. my anothor thread...........!!!:))

Can u tell me how can I format a hdd (with 75% bad sectors) by using this lang. I know its possible bcoz one of my friend works with a data recovery firm and after recovering data they simply format a damaged hdd and sell out on low prices.
 

MysticHalo

Your Maker.
[FONT=verdana, helvetica, arial, sans-serif]Java is now nearly equal to (or faster than) C++ on low-level and numeric benchmarks. This should not be surprising: Java is a compiled language (albeit JIT compiled). [/FONT] [FONT=verdana, helvetica, arial, sans-serif]Nevertheless, the idea that "java is slow" is widely believed. Why this is so is perhaps the most interesting aspect of this article. [/FONT]
[FONT=verdana, helvetica, arial, sans-serif]Let's look at several possible reasons: [/FONT]
  • [FONT=verdana, helvetica, arial, sans-serif]
    [*]Java circa 1995 was slow. The first incarnations of java did not java a JIT compiler, and hence were bytecode interpreted (like Python for example). JIT compilers appeared in JVMs from Microsoft, Symantec, and in Sun's java1.2. This explanation is implausible. Most "computer folk" are able to rattle off the exact speed in GHz of the latest processors, and they track this information as it changes each month (and have done so for years). Yet this explanation asks us to believe that they are not able to remember that a single and rather important language speed change occurred in 1996.
    [*] Java can be slow still. For example, programs written with the thread-safe Vector class are necessarily slower (on a single processor at least) than those written with the equivalent thread-unsafe ArrayList class. This explanation is equally unsatisfying, because C++ and other languages have similar "abstraction penalties". For example, The Kernighan and Pike book The Practice of Programming has a table with the following entries, describing the performance of several implementations of a text processing program:
    Version400 MHz PII C 0.30 sec C++/STL/deque 11.2 sec C++/STL/list 1.5 sec Another evidently well known problem in C++ is the overhead of returning an object from a function (several unnecessary object create/copy/destruct cycles are involved).
    [*]Java program startup is slow. As a java program starts, it unzips the java libraries and compiles parts of itself, so an interactive program can be sluggish for the first couple seconds of use. This approaches being a reasonable explanation for the speed myth. But while it might explain user's impressions, it does not explain why many programmers (who can easily understand the idea of an interpreted program being compiled) share the belief.
    [/FONT]
[FONT=verdana, helvetica, arial, sans-serif]Two of the most interesting observations regarding this issue are that: [/FONT]
  1. [FONT=verdana, helvetica, arial, sans-serif]
    [*] there is a similar "garbage collection is slow" myth that persists despite decades of evidence to the contrary, and
    [*] that in web flame wars, people are happy to discuss their speed impressions for many pages without ever referring to actual data.
    [/FONT]
[FONT=verdana, helvetica, arial, sans-serif]Together these suggest that it is possible that no amount of data will alter peoples' beliefs, and that in actuality these "speed beliefs" probably have little to do with java, garbage collection, or the otherwise stated subject. Our answer probably lies somewhere in sociology or psychology. Programmers, despite their professed appreciation of logical thought, are not immune to a kind of mythology, though these particular "myths" are arbitrary and relatively harmless.

Benchmarks here
IMo, JVM is a bigger nuisance than speed :(
[/FONT]
 

JGuru

Wise Old Owl
Why Sun has developed StarOffice & OpenOffice using C++?
The answer is most users have only 256 MB RAM.Big applications
like Office suite written in Java need 512 MB RAM or higher to
make it load fast. I use NetBeans , which is written in Java, so
your System should have a minimum of 512 MB RAM to run it
smoothly. Give it 1 GB RAM it will run even more faster!!
Since most of the users have either 128 or 256 MB RAM installed
in their System, Sun decided to write the Office suite in C++.
Or they could have written the whole thing in Java and compiled
it using a JIT compiler, which converts the bytecode to 'EXE'.
Sun could have written most of the Java API in C++, that would have
made Java zoom in Jet speed. But they didn't do it.
Of late Sun is trying to make Java more faster & stable.
 

abhasbajpai

Asterisk enthusiast
JGuru said:
Why Sun has developed StarOffice & OpenOffice using C++?
The answer is most users have only 256 MB RAM.Big applications
like Office suite written in Java need 512 MB RAM or higher Give it 1 GB RAM it will run even more faster!!.
now that answer the question that why java is for future use not for today maybe by than c++ will be evilved more than java and take its leap forward

Sun could have written most of the Java API in C++, that would have
made Java zoom in Jet speed. But they didn't do it.
Of late Sun is trying to make Java more faster & stable.
this defies suns perpose if they use c++ whats the use of java even in api
whel one more quetion when java can run on embeded systems having memories in less than tens of mb (like in cell phones where some times the memorie is less than 2mb) than why it needs such high reuirement on pc
 
Status
Not open for further replies.
Top Bottom