LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 12-16-2011, 05:12 PM   #16
Cedrik
Senior Member
 
Registered: Jul 2004
Distribution: Slackware
Posts: 2,140

Rep: Reputation: 244Reputation: 244Reputation: 244

Quote:
Originally Posted by hydraMax View Post
So, the kernel actually stores all this data in ASCII format in volatile memory, and then simply copies it out on request? Or does it make a binary to ASCII conversion whenever a call is made to read data from a proc file? You seem to be affirming the former, but as it is an important technically point I was hoping for clarification.
No, I made a confusion, the reading of a procfs file triggers a call back function,
so ascii char are produced on the fly
 
1 members found this post helpful.
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 08-02-2012, 12:05 AM   #17
ektoric
LQ Newbie
 
Registered: Jun 2001
Location: Austin, TX
Distribution: FC5/6
Posts: 23

Rep: Reputation: 15
Why provide a text interface to programs, and why encourage programmers to use the text based interface:

Two words: portability, and do-one-thing-and-do-it-well (yes, that's one word in *nix :-)

With a text based interface, you can write a script, use it on your Solaris box at work, your hp-ux-32bit box at school, and your Linux-64bit box at home. No need to write and compile a different binary on each system and architecture. One must remember that the *nix culture is that users *are* programmers. The ease of maintaining code outweigh the need for burning edge performance in all but the most extreme of cases. (Human readablilty is highly corrolated with maintainability.)

Another Unix culture is a "common" interface, that being printable ASCII. Any program that takes input as plain text and outputs as plain text can instantly be put it use in the middle of a pipe stream. Ever see those cat/grep/awk/sed/wc/etc... monstrosities? By providing a common text based interface, interesting heretofore unknown combinations can arise in the future.

By exposing a text interface as soon as possible out of kernel space, it allows a full suite of built in tools to become very powerful with a small footprint.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Pygame slow or just programmers are inefficient? General Programming 5 03-23-2010 04:06 AM
My system feels inefficient in its use of CPU power Changes Linux - General 7 10-06-2009 10:49 PM
Is Linux inherently unreliable? jacatone General 72 04-28-2009 03:39 PM
rsync - inefficient behaviour? Unclesmiff Linux - Software 4 01-02-2008 11:13 AM
Yum/Yumex Inherently Slow? sancho Linux - Software 3 09-06-2006 02:37 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 01:40 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration