Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Johnston <jjohnstn@redhat.com>2014-07-04 21:21:45 +0400
committerJeff Johnston <jjohnstn@redhat.com>2014-07-04 21:21:45 +0400
commitd34336767e45ee801ebb107e40abe4b1acbd3d14 (patch)
tree4b39e537048f743fc262f68c917df3592bac84d9 /newlib/README
parentfcef025b94860210c8567e87ca0df0220b2ff237 (diff)
2014-07-04 Bin Cheng <bin.cheng@arm.com>
* README (--enable-newlib-nano-formatted-io): Describe. * acconfig.h (_NANO_FORMATTED_IO): Undef. * newlib.hin (_NANO_FORMATTED_IO): Undef. * configure.in (--enable-newlib-nano-formatted-io): New option. * configure: Regenerated. * libc/configure.in (--enable-newlib-nano-formatted-io): New option. * libc/configure: Regenerated. * libc/stdio/Makefile.am (NEWLIB_NANO_FORMATTED_IO): Support new configuration option. * libc/stdio/Makefile.in: Regenerated. * libc/stdio/asnprintf.c (_asniprintf_r, asniprintf): Use _NANO_FORMATTED_IO to declare alias prototypes. * libc/stdio/asprintf.c (_asiprintf_r, asiprintf): Ditto. * libc/stdio/dprintf.c (_diprintf_r, diprintf): Ditto. * libc/stdio/fprintf.c (_fiprintf_r, fiprintf): Ditto. * libc/stdio/fscanf.c (fiscanf, _fiscanf_r): Ditto. * libc/stdio/printf.c (_iprintf_r, iprintf): Ditto. * libc/stdio/scanf.c (iscanf, _iscanf_r): Ditto. * libc/stdio/snprintf.c (_sniprintf_r, sniprintf): Ditto. * libc/stdio/sprintf.c (_siprintf_r, siprintf): Ditto. * libc/stdio/sscanf.c (siscanf, _siscanf_r): Ditto. * libc/stdio/vasnprintf.c (_vasniprintf_r, vasniprintf): Ditto. * libc/stdio/vasprintf.c (vasiprintf, _vasiprintf_r): Ditto. * libc/stdio/vdprintf.c (_vdiprintf_r, vdiprintf): Ditto. * libc/stdio/vprintf.c (viprintf, _viprintf_r): Ditto. * libc/stdio/vscanf.c (viscanf, _viscanf_r): Ditto. * libc/stdio/vsnprintf.c (vsniprintf, _vsniprintf_r): Ditto. * libc/stdio/vsprintf.c (vsiprintf, _vsiprintf_r): Ditto. * libc/stdio/vsscanf.c (vsiscanf, _vsiscanf_r): Ditto. * libc/stdio/nano-vfprintf.c: New file. * libc/stdio/nano-vfprintf_float.c: New file. * libc/stdio/nano-vfprintf_i.c: New file. * libc/stdio/nano-vfprintf_local.h: New file. * libc/stdio/nano-vfscanf.c: New file. * libc/stdio/nano-vfscanf_float.c: New file. * libc/stdio/nano-vfscanf_i.c: New file. * libc/stdio/nano-vfscanf_local.h: New file.
Diffstat (limited to 'newlib/README')
-rw-r--r--newlib/README67
1 files changed, 67 insertions, 0 deletions
diff --git a/newlib/README b/newlib/README
index adad87111..a3d915dda 100644
--- a/newlib/README
+++ b/newlib/README
@@ -372,6 +372,73 @@ One feature can be enabled by specifying `--enable-FEATURE=yes' or
invoke clean-up functions such as _fini or global destructors.
Disabled by default.
+`--enable-newlib-nano-formatted-io'
+ This builds NEWLIB with a special implementation of formatted I/O
+ functions, designed to lower the size of application on small systems
+ with size constraint issues. This option does not affect wide-char
+ formatted I/O functions. Some notes about the feature:
+ 1) The non-wide-char formatted I/O functions only support the C89
+ standard. The only exception is the configuration option provides
+ limited support for long double. Internally, the nano formatted I/O
+ functions use double so accuracy is only guaranteed to double
+ precision.
+ 2) Floating-point support is split out of the formatted I/O code into
+ weak functions which are not linked by default. Programs that need
+ floating-point I/O support must explicitly request linking of one or
+ both of the floating-point functions: _printf_float or _scanf_float.
+ This can be done at link time using the -u option which can be passed
+ to either gcc or ld. The -u option forces the link to resolve those
+ function references. Floating-point format specifiers are recognized
+ by default, but if the floating-point functions are not explicitly
+ linked in, this may result in undefined behavior for programs that
+ need floating-point I/O support.
+ 3) Integer-only versions of the formatted I/O functions (the iprintf/
+ iscanf family) simply alias their regular counter-parts.
+ The affected functions are:
+
+ diprintf vdiprintf
+
+ siprintf fiprintf iprintf sniprintf asiprintf asniprintf
+
+ siscanf fiscanf iscanf
+
+ viprintf vfiprintf vsiprintf vsniprintf vasiprintf vasniprintf
+
+ viscanf vfiscanf vsiscanf
+
+ _diprintf_r _vdiprintf_r
+
+ _siprintf_r _fiprintf_r _iprintf_r _sniprintf_r _asiprintf_r
+ _asniprintf_r
+
+ _siscanf_r _fiscanf_r _iscanf_r
+
+ _viprintf_r _vfiprintf_r _vsiprintf_r _asniprintf_r _vasiprintf_r
+ _vasniprintf_r
+
+ _viscanf_r _vfiscanf_r _vsiscanf_r
+
+ 4) As mentioned, the option does not affect wide-char formatted I/O.
+ The following configuration options are ignored for non-wide-char
+ formatted I/O functions, and can be thought of as disabled.
+
+ enable-newlib-io-pos-args
+ enable-newlib-io-c99-formats
+ enable-newlib-io-long-long
+ enable-newlib-io-long-double
+ enable-newlib-mb
+
+ Additionally, "enable/disable-newlib-io-float" is supported in
+ this specific implementation, one can use "disable-newlib-io-float"
+ to further reduce code size. In this case, the floating-point
+ specifiers will not be recognized or handled, and the -u option
+ will not work either.
+
+ 5) As a rule, no features from outside of C89 standard will be
+ considered in this implementation.
+
+ Disabled by default.
+
Running the Testsuite
=====================