Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #28091

Re: compile directly into a .zip/.jar file?

From Martin Gregorie <martin@address-in-sig.invalid>
Newsgroups comp.lang.java.programmer
Subject Re: compile directly into a .zip/.jar file?
Date 2014-04-15 12:51 +0000
Organization A noiseless patient Spider
Message-ID <lija0u$bte$1@dont-email.me> (permalink)
References <slrnlkicek.bi9.avl@login.logic.tuwien.ac.at> <1l96oa6aew63h$.1wt64t9w3vv91.dlg@40tude.net> <534ad197$0$301$14726298@news.sunsite.dk> <slrnlkm59e.bi9.avl@login.logic.tuwien.ac.at> <534c8e5e$0$297$14726298@news.sunsite.dk>

Show all headers | View raw


On Mon, 14 Apr 2014 21:41:50 -0400, Arne Vajhøj wrote:

> On 4/13/2014 6:52 PM, Andreas Leitgeb wrote:
>> Arne Vajhøj <arne@vajhoej.dk> wrote:
>>> If the goal is better performance,
>>
>> It's not like I wanted to squeeze another microsecond out of the
>> compile time, but more like trying to bypass some brake, that the
>> system has slammed full on for no good reason.
>>
>>> But with todays OS/file system caches and disk caches - likely in
>>> write back mode, then writing those class files to disk may not cause
>>> them to be actually written to the rotating plates before long after
>>> the process is completed from user perspective.
>>
>> Unless, maybe, the system believes that a file write/delete isn't done
>> until it's physically on the disk and some logs on another... Kind of
>> like some sync-flag was set. (maybe it even is - hardcoded)
> 
> That is how it always was in the old days.
>
AFAIK Unices have traditionally only automatically flushed buffers to 
disk in three circumstances: (1) if they run out of space in RAM, (2) 
when a process terminates all buffers get flushed and (3) output buffers 
are flushed if they haven't been written to for some time and contain 
unflushed data. Apart from that you can, of course, always call fflush() 
whenever the process logic requires, e.g. if a process periodically 
records a restartable checkpoint, it would probably flush buffers for all 
open files as part of recording the checkpoint. Its sometimes necessary, 
too, to flush stdout/stderr if the text is prompting for input read from 
stdin. In general this applies to Linux, and probably also to BSD and 
derivatives.

Other OSen may do things differently, e.g. OS/9, the real-time OS, writes 
blocks as soon as they are complete and when a file is closed, updating 
the file and disk management meta-data at the same time. This is 
deliberate: although it makes i/o a lot slower, its very rare indeed to 
to loose any data or to see a corrupt file in an OS/9 system unless 
you're using a dodgy disk.

Not doing much of the above is a main reason for FAT filing systems to be 
relatively fragile.


-- 
martin@   | Martin Gregorie
gregorie. | Essex, UK
org       |

Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

compile directly into a .zip/.jar file? Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-04-12 12:30 +0000
  Re: compile directly into a .zip/.jar file? Joerg Meier <joergmmeier@arcor.de> - 2014-04-12 15:02 +0200
    Re: compile directly into a .zip/.jar file? Roedy Green <see_website@mindprod.com.invalid> - 2014-04-12 19:56 -0700
      Re: compile directly into a .zip/.jar file? Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-04-13 15:29 +0000
    Re: compile directly into a .zip/.jar file? Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-04-13 15:19 +0000
      Re: compile directly into a .zip/.jar file? Roedy Green <see_website@mindprod.com.invalid> - 2014-04-13 17:35 -0700
    Re: compile directly into a .zip/.jar file? Arne Vajhøj <arne@vajhoej.dk> - 2014-04-13 13:53 -0400
      Re: compile directly into a .zip/.jar file? Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-04-13 22:21 +0000
        Re: compile directly into a .zip/.jar file? Arne Vajhøj <arne@vajhoej.dk> - 2014-04-13 18:40 -0400
    Re: compile directly into a .zip/.jar file? Arne Vajhøj <arne@vajhoej.dk> - 2014-04-13 14:04 -0400
      Re: compile directly into a .zip/.jar file? Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-04-13 22:52 +0000
        Re: compile directly into a .zip/.jar file? Arne Vajhøj <arne@vajhoej.dk> - 2014-04-14 21:41 -0400
          Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-15 12:51 +0000
            Re: compile directly into a .zip/.jar file? Arne Vajhøj <arne@vajhoej.dk> - 2014-04-15 20:00 -0400
              Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-16 12:29 +0000
                Re: compile directly into a .zip/.jar file? Jeff Higgins <jeff@invalid.invalid> - 2014-04-16 10:58 -0400
                Re: compile directly into a .zip/.jar file? Jeff Higgins <jeff@invalid.invalid> - 2014-04-16 12:45 -0400
                Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-16 19:33 +0000
                Re: compile directly into a .zip/.jar file? Jeff Higgins <jeff@invalid.invalid> - 2014-04-16 15:48 -0400
                Re: compile directly into a .zip/.jar file? Eric Sosman <esosman@comcast-dot-net.invalid> - 2014-04-16 16:20 -0400
                Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-16 22:31 +0000
                Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-16 18:43 +0000
                Re: compile directly into a .zip/.jar file? Arne Vajhøj <arne@vajhoej.dk> - 2014-04-16 18:33 -0400
                Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-17 12:58 +0000
  Re: compile directly into a .zip/.jar file? Roedy Green <see_website@mindprod.com.invalid> - 2014-04-12 19:54 -0700
    Re: compile directly into a .zip/.jar file? Andreas Leitgeb <avl@auth.logic.tuwien.ac.at> - 2014-04-13 16:08 +0000
  Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-13 23:25 +0000
    Re: compile directly into a .zip/.jar file? Arne Vajhøj <arne@vajhoej.dk> - 2014-04-14 21:40 -0400
      Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-15 13:38 +0000
        Re: compile directly into a .zip/.jar file? Arne Vajhøj <arne@vajhoej.dk> - 2014-04-15 19:49 -0400
          Re: compile directly into a .zip/.jar file? Martin Gregorie <martin@address-in-sig.invalid> - 2014-04-16 12:38 +0000
  Re: compile directly into a .zip/.jar file? Roedy Green <see_website@mindprod.com.invalid> - 2014-04-13 17:38 -0700

csiph-web