diff --git a/doc/index.html b/doc/index.html index 6cde0db..0ccac4e 100644 --- a/doc/index.html +++ b/doc/index.html @@ -39,17 +39,31 @@
+
+
Consider the following code:
@@ -166,8 +183,8 @@ integers. The types may be aligned.Boost Endian is a header-only library.
-The best approach to endianness for a particular use case depends on interactions between the approach characteristics and @@ -175,16 +192,16 @@ the application needs.
Recommendation: If you are uncertain, new to endianness, concerned about security, concerned about reliability, or don't want to invest time making -engineering trade-offs, use the endian arithmetic types. They are safer, easier +engineering trade-offs, use the endian arithmetic types. They are safer, easier to use, and your code will be easier to maintain.
-The characteristics that differentiate the three approaches to endianness are the endianness invariants, conversion explicitness, arithmetic operations, sizes available, and alignment requirements.
-@@ -202,7 +219,7 @@ That makes these types easier to use and programs easier to maintain.-
@@ -216,7 +233,7 @@ to hoist conversions out of inner loops can bring a performance penalty.-
@@ -233,7 +250,7 @@ are very easy to use if lots of arithmetic is involved.-
@@ -246,7 +263,7 @@ factor, using sizes tailored to application needs can be useful.-
@@ -277,7 +294,22 @@ needed they are often very useful and workarounds are painful. For example,@@ -747,7 +764,7 @@ and 16, 32, and 64-bit aligned integers.Use cases
-Porting endian aware codebase
+Porting endian unaware codebase
+ +An existing codebase runs on big endian systems. It does not +currently deal with endianness. The codebase needs to be modified so it can run +on little endian systems under various operating systems. To ease +transition and protect value of existing files, external data will continue to +be maintained as big endian.
+ +The endian +arithmetic approach is recommended to meet these needs. A relatively small +number of header files dealing with binary I/O layouts need to change types like +
+ +short
orint16_t
tobig_int16_t
, and +int
orint32_t
tobif_int32_t
. No +changes are required for.cpp
files.Porting endian aware codebase
An existing codebase runs on little-endian Linux systems. It already deals with endianness via @@ -292,22 +324,7 @@ approach that just mechanically changes the calls to
-htobe32
, etc. toboost::endian::native_to_big
, etc. and replaces<endian.h>
with<boost/endian/conversion.hpp>
.Porting endian unaware codebase
- -An existing codebase runs on expensive big endian systems. It does not -currently deal with endianness. The codebase needs to be modified so it can run -on lower-cost little endian systems under various operating systems. To ease -transition and protect value of existing files, external data will continue to -be maintained as big endian.
- -The endian -arithmetic approach is recommended to meet these needs. A relatively small -number of header files dealing with binary I/O layouts need to change types like -
- -short
orint16_t
tolittle_int16_t
, and -int
orint32_t
tolittle_int32_t
. No -changes are required for.cpp
files.Reliability and arithmetic-speed use case
+Reliability and arithmetic-speed
A new, complex, multi-threaded application is to be developed that must run on little endian machines, but do big endian network I/O. The developers believe @@ -319,7 +336,7 @@ slow conversions if full-blown endian arithmetic types are used.
The endian buffers approach is made-to-order for this use case.
-Reliability and ease-of-use use case
+Reliability and ease-of-use
A new, complex, multi-threaded application is to be developed that must run on little endian machines, but do big endian network I/O. The developers believe @@ -660,7 +677,7 @@ determine if some coding technique has significant impact on performance.
Unaligned types are much slower that aligned types, regardless of endianness considerations. Instead of single instruction register loads and -stores, multiple instructions are required.
+stores, multiple instructions are required on common platforms.
The endian types have been decomposed into endian buffer types diff --git a/doc/mini_review_topics.html b/doc/mini_review_topics.html index 286033b..e9ec002 100644 --- a/doc/mini_review_topics.html +++ b/doc/mini_review_topics.html @@ -18,7 +18,7 @@
Common use case scenarios should be developed.
-+
Done. See Use cases.
Example programs should be developed for the common use case scenarios.
@@ -29,9 +29,8 @@ integer/float type and endian conversion approaches to the common use case scenarios, and provide guidelines for choosing the most appropriate approach in user's applications.-Done. See Choosing between - endian types and - endian conversion functions.
+Done. See Choosing between endian conversion + functions, endian buffer types, and endian arithmetic types.
Conversion functions supplying results via return should be provided.
@@ -99,7 +98,7 @@ might used inadvertently or inappropriately. The impact of adding an endian_buff
Last revised: -05 December, 2014
+17 December, 2014© Copyright Beman Dawes, 2014
Distributed under the Boost Software License, Version 1.0. See www.boost.org/ LICENSE_1_0.txt
diff --git a/doc/publish.bat b/doc/publish.bat index a79a067..a6b6e9a 100644 --- a/doc/publish.bat +++ b/doc/publish.bat @@ -1,6 +1,6 @@ copy /y c:\boost\modular\develop\libs\endian\doc\* d:\boost\endian-gh-pages pushd d:\boost\endian-gh-pages -git commit -a +git commit -a -m "sync with develop" git push popd rem Copyright Beman Dawes, 2013