Unixmen - Tips to reduce memory usage on Firefox

2010-07-14 1 min read Firefox Uncategorized

A nice aritcle on reducing the memory usage of firefox on <a class="zem_slink" title="Linux" rel="wikipedia" href="http://en.wikipedia.org/wiki/Linux">Linux.

There are some things in life everyone is looking for and no one ever finds and there are other things that people keep finding and re-finding and inventing and re-inventing. Reducing memory usage for <a class="zem_slink" title="Firefox" rel="homepage" href="http://www.mozilla.com/firefox/">Firefox and speeding it up is one such thing. So, here is another story to reduce the memory usage of firefox.

Continue reading

Google\’s RE2 regular expression library

2010-05-30 0 min read Bash
\"Image
Image via CrunchBase

?

<a class="zem_slink freebase/en/google" title="Google" rel="homepage" href="http://google.com">Google has announced the release of its RE2 library under a BSDish license. &#8221;At Google, we use <a class="zem_slink freebase/en/regular_expression" title="Regular expression" rel="wikipedia" href="http://en.wikipedia.org/wiki/Regular_expression">regular expressions as part of the interface to many external and internal systems, including Code Search, <a class="zem_slink freebase/en/sawzall" title="Sawzall (programming language)" rel="wikipedia" href="http://en.wikipedia.org/wiki/Sawzall_%28programming_language%29">Sawzall, and <a class="zem_slink" title="Bigtable" rel="homepage" href="http://labs.google.com/papers/bigtable.html">Bigtable. Those systems process large amounts of <a class="zem_slink freebase/en/data" title="Data" rel="wikipedia" href="http://en.wikipedia.org/wiki/Data">data; exponential <a class="zem_slink freebase/en/runtime" title="Run time (computing)" rel="wikipedia" href="http://en.wikipedia.org/wiki/Run_time_%28computing%29">run time would be a serious problem. On a more practical note, these are <a class="zem_slink freebase/en/thread" title="Thread (computer science)" rel="wikipedia" href="http://en.wikipedia.org/wiki/Thread_%28computer_science%29">multithreaded <a class="zem_slink freebase/en/cplusplus" title="C++" rel="wikipedia" href="http://en.wikipedia.org/wiki/C%2B%2B">C++ programs with fixed-size stacks: the unbounded stack usage in typical regular expression implementations leads to stack overflows and server crashes. To solve both problems, we&#8217;ve built a new regular expression engine, called RE2, which is based on <a class="zem_slink freebase/en/automata_theory" title="Automata theory" rel="wikipedia" href="http://en.wikipedia.org/wiki/Automata_theory">automata theory and guarantees that searches complete in <a class="zem_slink freebase/en/linear_time" title="Linear time" rel="wikipedia" href="http://en.wikipedia.org/wiki/Linear_time">linear time with respect to the size of the input and in a fixed amount of stack space.&#8221; More information can be found on the <a href="http://code.google.com/p/re2/" target="_blank">RE2 project page.<h6 class="zemanta-related-title">Related articles by Zemanta <ul class="zemanta-article-ul"> <li class="zemanta-article-ul-li"><a href="http://glinden.blogspot.com/2010/03/gfs-and-its-evolution.html">GFS and its evolution (glinden.blogspot.com) <li class="zemanta-article-ul-li"><a href="http://research.swtch.com/2010/03/regular-expression-article-3.html">Regular Expression Article #3 (research.swtch.com) <div class="zemanta-pixie"><a class="zemanta-pixie-a" title="Reblog this post [with Zemanta]" href="http://reblog.zemanta.com/zemified/456fa268-f416-4aec-ae05-4d1a9c9c2712/"><img class="zemanta-pixie-img" src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/reblog_b65.png" alt="Reblog this post [with Zemanta]" /><span class="zem-script more-related more-info pretty-attribution paragraph-reblog">

Continue reading

Awk Introduction Tutorial – 7 Awk Print Examples

2010-05-19 0 min read Bash Fedora Linux
\"LAS
Image by Getty Images via Daylife

awk examples

Awk Introduction Tutorial – 7 Awk Print Examples This is the first article on the new awk tutorial series. We’ll be posting several articles on awk in the upcoming weeks that will cover all features of awk with practical examples. In this article, let us review the fundamental awk working methodology along with 7 practical awk print examples. Note: Make sure you review our earlier […]

Continue reading

Find out why a program can't seem to access to a file

2010-05-05 2 min read Fedora Linux

$ strace php tias.php -e open,access 2>&1 | <a class="zem_slink freebase/en/grep" href="http://en.wikipedia.org/wiki/Grep" title="Grep" rel="wikipedia">grep foo.txt Sometimes a program refuses to read a file and you&#8217;re not sure why. You may have display_errors turned off for <a class="zem_slink freebase/en/php" href="http://www.php.net/" title="PHP" rel="homepage">PHP or something. In this example, fopen(&#8217;/var/www/test/foo.txt&#8217;) was called but doesn&#8217;t have read access to foo.txt.

Strace can tell you what went wrong. E.g., if php doesn&#8217;t have read access to the file, strace will say &#8221;EACCESS (Permission denied)&#8221;. Or, if the <a class="zem_slink freebase/guid/9202a8c04000641f8000000000220ffa" href="http://en.wikipedia.org/wiki/Path_%28computing%29" title="Path (computing)" rel="wikipedia">file path you gave doesn&#8217;t exist, strace will say &#8221;ENOENT (No such file or directory)&#8221;, etc.

Continue reading

String and Array Creation

2010-04-28 0 min read Learning Linux Perl
\"Perl\"
Image via Wikipedia

<img src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/perl-one-liners.jpg" alt="Perl One Liners" align="bottom" />This is the fourth part of a nine-part article on famous <a class="zem_slink freebase/en/perl" title="Perl" rel="homepage" href="http://www.perl.org/">Perl one-liners. In this part I will create various one-liners for string and array creation. See <a href="http://www.catonmat.net/blog/perl-one-liners-explained-part-one/">part one for introduction of the series.

Famous Perl one-liners is my attempt to create “perl1line.txt” that is similar to “<a href="http://www.catonmat.net/blog/awk-one-liners-explained-part-one/">awk1line.txt” and “<a href="http://www.catonmat.net/blog/sed-one-liners-explained-part-one/">sed1line.txt” that have been so popular among Awk and Sed programmers.

Continue reading

Create your own splash screen for gimp

2010-04-05 0 min read Fedora Photo
\"Category:Created
Image via Wikipedia

Gimp allows you to set the <a class="zem_slink freebase/en/splash_screen" title="Splash screen" rel="wikipedia" href="http://en.wikipedia.org/wiki/Splash_screen">splash screen very easily. All you need to do is copy the image to ~/.gimp-/splashes/. There is <a class="zem_slink freebase/en/betting" title="Betting (poker)" rel="wikipedia" href="http://en.wikipedia.org/wiki/Betting_%28poker%29">no limit on the size or color. You just copy all the images you like to have as splash and one of them would be randomly picked up from the said direcotory for the splash image.

Continue reading

Photo Compositing with the GIMP

2010-03-25 1 min read Photo

Basing from my previous <a class="zem_slink freebase/en/gimp" title="GIMP" rel="homepage" href="http://www.gimp.org/">GIMP article titled Creating Pseudo-3D Imagery with GIMP, you learned how to do some basic selection manipulation, gradient application, faking <a class="zem_slink freebase/en/depth_of_field" title="Depth of field" rel="wikipedia" href="http://en.wikipedia.org/wiki/Depth_of_field">Depth of Field, etc. In line with that, I’m following it with a new article very much related to the concepts discussed therein but we’ll raise the bar a bit by having a glimpse on <a class="zem_slink freebase/en/compositing" title="Compositing" rel="wikipedia" href="http://en.wikipedia.org/wiki/Compositing">compositing, where we’ll use an existing <a class="zem_slink freebase/en/image" title="Image" rel="wikipedia" href="http://en.wikipedia.org/wiki/Image">image or <a class="zem_slink freebase/en/photograph" title="Photograph" rel="wikipedia" href="http://en.wikipedia.org/wiki/Photograph">photograph and later add in our <a class="zem_slink freebase/en/dimension" title="Dimension" rel="wikipedia" href="http://en.wikipedia.org/wiki/Dimension">2-dimensional element seamlessly with the said picture.

Continue reading
Older posts Newer posts