Commit Graph

39518 Commits

Author SHA1 Message Date
Paulo Matos
1722e49c85 Remove dead code
I understand what the idea is in this file, except this code won't
work like the author expected it to. Variables marked for wiping won't
be wiped unless they are marked as volatile. The compiler will simply
remove the code wiping the variables and issue a warning, which is
what brought me to look into this code in the first place.
2019-02-14 08:09:26 -08:00
Paulo Matos
136ea767e2 Free memory stored when error occurs - otherwise buffer leaks 2019-02-14 08:08:27 -08:00
Paulo Matos
14499aa822 Free buffer in case of unknown error - avoids memory leak 2019-02-14 08:07:49 -08:00
Paulo Matos
4014b066d1 Remove assignment - value stored to cpos is never read 2019-02-14 08:06:39 -08:00
Paulo Matos
04e6422c72 Ensure copied is not overwritten by another strdup causing a leak 2019-02-14 08:04:38 -08:00
Matthew Flatt
e7e9d02c9e native-libs: patches to adjust Pango font-face matching 2019-02-14 08:57:51 -07:00
Matthew Flatt
ecf3766d96 io: reduce overhead on display and write-bytes 2019-02-13 16:18:22 -07:00
Matthew Flatt
17c46c9c36 io: fix file and TCP ports as place messages 2019-02-13 10:48:55 -07:00
Matthew Flatt
a4bd83011b io: fix result of file-stream-port? 2019-02-13 10:41:12 -07:00
Matthew Flatt
5339a36187 io: fix file-stream-buffer-mode on file output ports 2019-02-13 10:20:04 -07:00
Matthew Flatt
c2d53143c1 io: improve syntax of internal class forms 2019-02-13 10:08:58 -07:00
Matthew Flatt
d197e1b8f4 io: adjust read-[bytes-]line to use direct buffer 2019-02-13 10:08:58 -07:00
Matthew Flatt
e266da929d io: fix pipe slow path and GC
Make the slow path faster by reducing input- and output-end
coordination. Also, avoid retaining one end just because the other end
is retained.

This change involves adding an indirection for the fast-path buffers
so that management for both ends of a pipe can be centralized
independent of the ports.
2019-02-13 10:08:58 -07:00
Matthew Flatt
f0aa8573fe io: repair some buffer + counting interactions 2019-02-13 10:08:58 -07:00
Matthew Flatt
6fb4097fef io: make fd-output-port use the fast path 2019-02-13 10:08:58 -07:00
Matthew Flatt
45347465df io: add output fast path
Add a fast path for output that is like input, based on a exposed
buffer. Make bytes-output-port and pipe use it.
2019-02-13 10:08:58 -07:00
Matthew Flatt
d6af78cebd io: convert tcp-{input,output}-port to object style 2019-02-13 10:08:58 -07:00
Matthew Flatt
01d53378b2 io: partial streamline of fd ports
Further improvements to move away from the `data` field.
2019-02-13 10:08:58 -07:00
Matthew Flatt
a382c6ca72 io: clean up unneeded scaffolding
Everything is converted, so we don't need the scaffolding anymore.
2019-02-13 10:08:58 -07:00
Matthew Flatt
40f27f8153 io: convert make-output-port to object style 2019-02-13 10:08:58 -07:00
Matthew Flatt
c57b52eb70 io: convert make-input-port to object style
Sortof. This is where we especially take advantage of vtable
flexibility. The methods of the vtable are really closures,
because that's far more convenient for custom ports.
2019-02-13 10:08:58 -07:00
Matthew Flatt
6e85165b3c io: convert fd-output-port to object style 2019-02-13 10:08:58 -07:00
Matthew Flatt
c28a0f45dc io: (mostly) keep fast path when line counting is enabled 2019-02-13 10:08:58 -07:00
Matthew Flatt
e3b00715bc io: convert fd-input-port to object style 2019-02-13 10:08:58 -07:00
Matthew Flatt
95083d6add io: add peek-via-read layer as prep for fd and custom ports 2019-02-13 10:08:58 -07:00
Matthew Flatt
35ceb8e3b3 io: convert pipe to object style 2019-02-13 10:08:58 -07:00
Matthew Flatt
78136c0613 io: convert bytes-output-port to object style 2019-02-13 10:08:57 -07:00
Matthew Flatt
d8521e8486 io: start conversion to classes
Change the internal port representation to an object-with-vtable
representation. The syntax looks similar to the class system of
`racket/class`, but everything is first-order: no class values, no
mixins, etc. Also, the vtable can contain non-procedures (like #f for
"not supported" or a port to mean a direcirection).

Using objects will make port instaces smaller and support a
reorganization to eliminate ad hoc `data`-field extensions. It will
also replace a half-step was was in place for byte input

Along with the conversion, change the way the fast path for writing
works: When possible, expose a shared buffer and index into that
buffer.

Only byte string input ports are really converted, so far. A
compatibility layer maps the old protocol to the new one, so
conversion can continue piecewise.
2019-02-13 10:08:57 -07:00
Paulo Matos
f8a130851f Install uuid-dev for missing uuid.h 2019-02-11 16:52:24 -05:00
Paulo Matos
184bed291c Fix call to scan-build to use version 9 2019-02-11 16:52:24 -05:00
Paulo Matos
c438a88595 Use racketcs/racocs and build using clang-9 2019-02-11 16:52:24 -05:00
Paulo Matos
cc62c9214c Missing before script 2019-02-11 16:52:24 -05:00
Paulo Matos
dba2bee713 Add scan-build support using llvm-8 to racket and racketcs build 2019-02-11 16:52:24 -05:00
Paulo Matos
948dc49e90 Create .gitlab-ci.yml to compile/test racket and racketcs with ubsan 2019-02-11 16:52:24 -05:00
Matthew Flatt
e60b24c1a9 io: fix (find-system-file 'pref-file)
Corrects a mistake in 5c775fa04c.
2019-02-09 10:48:25 -07:00
Matthew Flatt
44368147f2 cs: small shortcut for mark lookup 2019-02-09 10:48:25 -07:00
Matthew Flatt
3c030b143b expander: extend "illegal use of syntax" error
Show the compile-time value that is not a procedure. While
this runs some risk of exposing details that are meant
to be private to a macro/language, a macro/language can
use an applicable structure to provide a more specific
error message. Meanwhile, showing the value is likely to
help for someone who needs to debug a macro problem.
2019-02-09 10:48:25 -07:00
Robby Findler
4ed5d7d98b added struct-guard/c 2019-02-09 09:18:58 -06:00
Matthew Flatt
5c775fa04c io: find-system-path and directory results
Use `path->directory-path` to ensure consistent trailing slashes.

Closes #2461
2019-02-07 09:12:12 -08:00
Matthew Flatt
2754d4e5a0 cs: avoid cont-mark conversion on capture
A conversion from assoc list to hash table is a leftover of a previous
stretegy, and it does not seem useful anymore.
2019-02-05 08:48:08 -08:00
Matthew Flatt
2abe2a48b4 bump version to sync cs changes 2019-02-05 08:23:37 -08:00
Matthew Flatt
e1cc9b2a80 cs: speed up sync on combination with never-evt 2019-02-04 06:42:33 -08:00
Matthew Flatt
61ca9ef474 cs: speed up break-enabled slightly 2019-02-04 06:23:15 -08:00
Matthew Flatt
b1bdcacabc io: slightly faster read-line 2019-02-03 15:28:18 -08:00
Matthew Flatt
af24a0318f io: faster read-char 2019-02-03 14:46:02 -08:00
Matthew Flatt
9823cbba4d io: reduce overhead on read-byte and read-char 2019-02-03 13:52:20 -07:00
Matthew Flatt
5ffb96e62d cs: reduce the cost of entering & exiting atomic mode 2019-02-03 10:33:15 -07:00
Matthew Flatt
941fe38cee check JIT and extflonum operations that are not supported
Goes with 80f84f2132.
2019-02-02 19:55:26 -07:00
Matthew Flatt
80f84f2132 fix extflvector-length for platforms where it's not inlined 2019-02-02 19:38:41 -07:00
Matthew Flatt
db760fe748 makefile: avoid stderr more for Chez Scheme build 2019-02-02 13:13:22 -07:00