[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Reading portions of large files
From: |
David Kastrup |
Subject: |
Re: Reading portions of large files |
Date: |
10 Jan 2003 21:51:49 +0100 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 |
"Eli Zaretskii" <eliz@is.elta.co.il> writes:
> > From: David Kastrup <dak@gnu.org>
> > Newsgroups: gnu.emacs.help
> > Date: 09 Jan 2003 19:20:06 +0100
> >
> > > I have very large files, sometimes over 1G, from which I would
> > > like to edit very small portions, the headers or trailers for
> > > example. Emacs won't open those files, it complains about them
> > > being too big. Is it possible to edit, and save back after
> > > editing, only small portions of such files.
> >
> > insert-file-contents is a built-in function.
> > (insert-file-contents FILENAME &optional VISIT BEG END REPLACE)
>
> I don't think this will help the OP, since BEG and END need to be
> representable as Lisp integers, so they still are subject to the same
> 128-MB limit.
Oops, I forgot. In that case it would probably be best to run dd
from or to pipes with appropriate options for writing and reading
pieces from a big file.
BTW, would it be terribly complicated to extend the range of Lisp
integers to 31bit? Integers don't need any garbage collection or tag
bits per se. One could still use, say, the upper byte (or a smaller
unit) as a tag byte, only that the first or last 128 values would all
signify "integer".
Emacs has a most-positive-fixnum of 134217727, while XEmacs has
1073741823, more than 8 times as much. So it would appear to be
possible in theory.
--
David Kastrup, Kriemhildstr. 15, 44793 Bochum
- Reading portions of large files, Gerald . Jean, 2003/01/09
- Re: Reading portions of large files, David Kastrup, 2003/01/09
- Re: Reading portions of large files, Eli Zaretskii, 2003/01/10
- Message not available
- Re: Reading portions of large files, Stefan Monnier <address@hidden>, 2003/01/13
- Re: Reading portions of large files, Miles Bader, 2003/01/13
- Re: Reading portions of large files, Miles Bader, 2003/01/13
- Re: Reading portions of large files, David Kastrup, 2003/01/13
- Re: Reading portions of large files, Miles Bader, 2003/01/13
- Re: Reading portions of large files, Lee Sau Dan, 2003/01/20
- Re: Reading portions of large files, Mac, 2003/01/24
- Re: Reading portions of large files, Stefan Monnier <address@hidden>, 2003/01/27