Update of /cvsroot/monetdb/MonetDB4/src/modules/plain
In directory sc8-pr-cvs16.sourceforge.net:/tmp/cvs-serv15343/src/modules/plain

Modified Files:
        alarm.mx algebra.mx arith.mx ascii_io.mx bat.mx bat_arith.mx 
        builtin.mx counters.mx decimal.mx logger.mx mkey.mx 
        monettime.mx pcl.mx pcre.mx profiler.mx radix.mx str.mx sys.mx 
        tcpip.mx trans.mx unix.mx xtables.mx 
Log Message:
propagated changes of Sunday Feb 03 2008 - Friday Feb 08 2008
from the MonetDB_4-22 branch to the development trunk


Index: trans.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/trans.mx,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- trans.mx    11 Jan 2008 10:38:54 -0000      1.3
+++ trans.mx    8 Feb 2008 22:36:06 -0000       1.4
@@ -18,7 +18,6 @@
 @t Transactions
 @a M.L. Kersten, P. Boncz
 @v 1.0
[EMAIL PROTECTED]
 @* Introduction
 In the philosophy of Monet, transaction management overhead should only
 be paid when necessary. Transaction management is for this purpose

Index: pcl.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/pcl.mx,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- pcl.mx      11 Jan 2008 10:38:54 -0000      1.4
+++ pcl.mx      8 Feb 2008 22:36:06 -0000       1.5
@@ -18,7 +18,6 @@
 @a N. Nes
 @t PCL - The Performance Counter Library
 @v 2.2, January 2003
[EMAIL PROTECTED]
 PCL (The Performance Counter Library) is a common interface to access
 in a portable way performance counters built into modern
 microprocessors. PCL supports query for functionality, start and stop

Index: monettime.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/monettime.mx,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- monettime.mx        11 Jan 2008 10:38:54 -0000      1.7
+++ monettime.mx        8 Feb 2008 22:36:06 -0000       1.8
@@ -20,7 +20,6 @@
 @v 1.0
 
 @* Introduction
[EMAIL PROTECTED]
 The goal of this module is to provide adequate functionality for storing
 and manipulated time-related data. The minimum requirement is that data
 can easily be imported from all common commercial RDBMS products.
@@ -31,7 +30,6 @@
 The starting point of this module are SQL 92 and the ODBC time-related data 
types.
 Also, some functionalities have been imported from the time classes of the Java
 standard library.
[EMAIL PROTECTED]
 This module introduces four basic types and operations on them:
 \begin{description}
 \item[date] a date in the Gregorian calendar, e.g. 1999-JAN-31
@@ -58,7 +56,6 @@
 \end{description}
 
 @- Limitations
[EMAIL PROTECTED]
 The valid ranges of the various data types are as follows:
 \begin{description}
 \item[min and max year]
@@ -159,7 +156,6 @@
 .MODULE monettime;
 
 @- date atom
[EMAIL PROTECTED]
 Monet atoms can have multiple {\em parse formats}. One of these formats is
 chosen as the {\em print format}.
 
@@ -204,7 +200,6 @@
 
 @- daytime atom
 @+ Daytime atom
[EMAIL PROTECTED]
 A valid time of day to the detail of milliseconds, like 23:59:59:000
 {\small
 \begin{verbatim}
@@ -236,7 +231,6 @@
 
 
 @- timestamp
[EMAIL PROTECTED]
 An absolute point of time, as formed by the combination of a date a daytime in 
GMT
 e.g. [EMAIL PROTECTED]:59:59:000. GMT is the universal time at the Greenwich 
meridian,
 without any daylight savings time (DST). As such GMT times are 'absolute' 
(continuous,
@@ -273,7 +267,7 @@
 .OPERATOR0 (timestamp) "<=" (timestamp) : bit = timestamp_comp_LE;  "timestamp 
smaller-or-equal test (!DS2.2)"
 .OPERATOR0 (timestamp) ">=" (timestamp) : bit = timestamp_comp_GE;  "timestamp 
greater-or-equal test (!DS2.2)"
 
[EMAIL PROTECTED]
+@
 When creating a timestamp from a date and daytime, a timezone should be 
specified
 (if timezone is omitted, the local timezone is assumed). If a timezone is 
specified,
 it is used to convert the date and time in that timezone to GMT, which is the 
internal
@@ -284,7 +278,6 @@
 occurrence (still within DST).
 
 @- tzone
[EMAIL PROTECTED]
 A timezone determines a {\em time offset} from GMT with format
 [-] HOUR ':' MINUTES, with HOUR between [0:23] and MINUTES between [0:59].
 
@@ -356,7 +349,6 @@
        "create a tzone as an hour difference from GMT and a DST. (!DS2.2)"
 
 @- Time/date decomposition
[EMAIL PROTECTED]
 There are routines that decompose a date and routines that decompose a daytime.
 For decomposing a timestamp, there are routines that decompose it in a date
 and daytime. The bulk variants are also provided to simplify code
@@ -418,7 +410,6 @@
        "extract minutes from rule (!DS2.2)."
 
 @- Time/date arithmetic
[EMAIL PROTECTED]
 We choose to represent intervals of time as numbers of days (as int, a 32-bits 
integer)
 and numbers of milliseconds (as lng, a 64-bits integer). Using standard 
integer types
 facilitates computation with these amounts of time (you can use all normal 
integer

Index: builtin.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/builtin.mx,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- builtin.mx  11 Jan 2008 10:38:54 -0000      1.6
+++ builtin.mx  8 Feb 2008 22:36:06 -0000       1.7
@@ -21,7 +21,7 @@
 
 @* Introduction
 Apart from its grammatical structure, described in the
[EMAIL PROTECTED]<a href="../../../FrontEnds/mil/index.html">MIL Manual</a>@, 
MIL is just a set
[EMAIL PROTECTED]<a 
href="_ROOTURL_/MonetDB/Version4/Documentation/mil/index.html">MIL Manual</a>@, 
MIL is just a set
 of commands. When MIL is bootstrapped, this set of commands
 is the empty set.
 

Index: tcpip.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/tcpip.mx,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- tcpip.mx    11 Jan 2008 10:38:54 -0000      1.10
+++ tcpip.mx    8 Feb 2008 22:36:06 -0000       1.11
@@ -20,7 +20,6 @@
 @t TCP/IP Communication
 
 @* Introduction
[EMAIL PROTECTED]
 With this module you can establish TCP/IP connections between Mservers,
 and pass BATs {\em or any other MIL value} asynchronously between them.
 Mode of operation:
@@ -732,7 +731,6 @@
 
 
 @- the connection waiter
[EMAIL PROTECTED]
 is a thread created individually for each opened TCP/IP connection.
 It waits for requests that can be one of three different things:
 \begin{itemize}

Index: ascii_io.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/ascii_io.mx,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -d -r1.20 -r1.21
--- ascii_io.mx 11 Jan 2008 10:38:54 -0000      1.20
+++ ascii_io.mx 8 Feb 2008 22:36:06 -0000       1.21
@@ -19,7 +19,6 @@
 @a Niels Nes
 @* Ascii io Module
 
[EMAIL PROTECTED]
 A database cannot live with out bulk load/store operations. The ASCII io
 module can be used bulk load from an ASCII file or dump to one.
 The file can plain ASCII, gzipped or bzipped, decided by the extension

Index: counters.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/counters.mx,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- counters.mx 11 Jan 2008 10:38:54 -0000      1.3
+++ counters.mx 8 Feb 2008 22:36:06 -0000       1.4
@@ -17,7 +17,6 @@
 @f counters
 @a S. Manegold, P. Boncz
 @t Performance Counters
[EMAIL PROTECTED]
 This is a memory/cpu performance measurement tool for
 the following processor (families).
 \begin{tabular}{l}

Index: mkey.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/mkey.mx,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- mkey.mx     11 Jan 2008 10:38:54 -0000      1.5
+++ mkey.mx     8 Feb 2008 22:36:06 -0000       1.6
@@ -59,7 +59,6 @@
 sides and then join these keys.
 
 Example :
[EMAIL PROTECTED]
 \begin{verbatim}
 orders                  customer                link
 ====================    =====================   ===========
@@ -117,7 +116,6 @@
 that together with a simple MIL join:
 
 join(ds\_hash(keys), ds\_hash(keys.reverse);
[EMAIL PROTECTED]
 One complication of this procedure are nil values:
 \begin{itemize}
 \item it may happen that the final hash-value (an int formed by a

Index: unix.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/unix.mx,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- unix.mx     11 Jan 2008 10:38:54 -0000      1.3
+++ unix.mx     8 Feb 2008 22:36:06 -0000       1.4
@@ -20,7 +20,6 @@
 @d 06/06/2001
 @v 0.2
 
[EMAIL PROTECTED]
 @* Unix stdlib
 
 Provides access to some of the C stdlib.h functions.

Index: bat.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/bat.mx,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- bat.mx      11 Jan 2008 10:38:54 -0000      1.17
+++ bat.mx      8 Feb 2008 22:36:06 -0000       1.18
@@ -18,7 +18,6 @@
 @v 1.0
 @a Peter Boncz, M.L. Kersten
 @* Binary Association Tables
[EMAIL PROTECTED]
 This module contains all commands that are of use when managing Binary
 Association Tables (BATs). The relational operations you can execute
 on BATs have the form of a @[<a href="../algebra/index.html">neat algebra</a>@.
@@ -176,7 +175,6 @@
 .COMMAND inplace( BAT[void,any::1] o, BAT[oid,any::1] d, bit force ) : 
BAT[void,any::1] = bat_inplace_force; "inplace replace values on the given 
locations"
 
 @- BAT properties
[EMAIL PROTECTED]
 Monet maintains a number of {\em properties} on each BAT that is used to steer 
tactical
 query optimization (i.e. choosing a good algorithms for a particular algebra 
command).
 
@@ -371,7 +369,6 @@
  '[EMAIL PROTECTED](v)..' iterates over all BUNs [$h,$t] of BAT b where ($h = 
val)."
 
 @- BAT I/O, Persistency
[EMAIL PROTECTED]
 The BAT Buffer Pool (BBP) manages all known BATs. It administers
 their logical and physical names and a reference count. BATs can
 be {\em persistent}, {\em transient} or {\em session}. The BBP also manages
@@ -428,7 +425,6 @@
 
 
 @- Heap Specific Commands
[EMAIL PROTECTED]
 BATs are stored in memory in a number of Heap objects. A heap is nothing
 more than a contiguous range of memory. Bats are saved to disk by just writing
 away their image. This approach without pointer swizzling makes it possible
@@ -1801,7 +1797,6 @@
 }
 
 @+ Page-wise BAT remappings
[EMAIL PROTECTED]
 The XML node storage scheme of MonetDB/XQuery needs some extra kernel support. 
 
 \begin{itemize}
@@ -1871,7 +1866,6 @@
 zero cost.
 
 @- Remapped Copy
[EMAIL PROTECTED]
 CMDremap makes a copy of a bat, putting the logical 'pages' (REMAP_PAGE_SIZE 
tuples) in an 
 alternative order, specified by a map. It is optimized to use copy-on-write 
memory 
 mappings to make cheap copies, when possible.

Index: algebra.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/algebra.mx,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- algebra.mx  11 Jan 2008 10:38:54 -0000      1.10
+++ algebra.mx  8 Feb 2008 22:36:06 -0000       1.11
@@ -206,7 +206,6 @@
 "Fill the tail column with a constant value."
 
 @+ Sets
[EMAIL PROTECTED]
 Sets in Monet can be viewed in two ways:
 \begin{itemize}
 \item by looking at both columns of a BAT together (Set-, or s-operators).
@@ -219,7 +218,6 @@
 \end{itemize}
 @
 
[EMAIL PROTECTED]
 Operands provided are:
 \begin{itemize}
 \item {\tt [s,k]unique} (bat[any::1,any::2]) : bat[any::1,any::2]\\
@@ -519,7 +517,6 @@
 "has fast implementation: histogram(bat.reverse)"
 
 @- Default Min and Max
[EMAIL PROTECTED]
 Implementations a generic Min and Max routines get declared first. The
 {\tt min()} and {\tt max()} routines below catch any tail-type.
 The type-specific routines defined later are faster, and will
@@ -537,7 +534,6 @@
                        : any::2 = CMDmaxany; "
 Give the highest tail value. Error on empty BATs."
 @+ Type-Specific Sum, Product, Max and Min
[EMAIL PROTECTED]
 For X $\in$ \{ bte,sht,int,wrd,flt,dbl,lng \}, we define (using the {\em 
aggregate}
 macro):
 \begin{itemize}
@@ -1141,7 +1137,6 @@
 No Prolog code is used and the information is retained
 as it illustrates many of the issues.
 @+ Modeling With Properties
[EMAIL PROTECTED]
 The Monet kernel performs {\em run-time optimizations}. To choose between
 alternative algorithms in a sensible way, it maintains knowledge about
 each BAT, sometimes as a {\em BAT property}, sometimes as two
@@ -1156,7 +1151,6 @@
 using the mirror BAT with the minus operator ({\tt ordered(-BAT)}).
 
 @- Column Properties
[EMAIL PROTECTED]
 \begin{description}
 \item[{\tt ordered(BAT) : bit}]
        TRUE if the head column is stored in ascending order, else FALSE.
@@ -1179,7 +1173,6 @@
 \end{description}
 
 @- BAT properties
[EMAIL PROTECTED]
 \begin{description}
 \item[{\tt size(BAT) : int}]
        The (estimated) length of a column.
@@ -1193,7 +1186,6 @@
 \end{description}
 
 @- Property Propagation Rules
[EMAIL PROTECTED]
 At database creation time, the properties of the BATs in the database
 can be derived directly from the database schema.
 
@@ -1212,7 +1204,6 @@
 of standard algebraic MIL operators.
 
 @- Kernel vs Model Properties
[EMAIL PROTECTED]
 The properties managed by the model are a superset of the ones maintained
 run-rime by the query. The reason for this follows:
 
@@ -1231,7 +1222,6 @@
 although they do not occur in the Monet kernel at run-time.
 
 @- Cost Functions
[EMAIL PROTECTED]
 With the property propagation rules in hand, for each algebraic operator,
 split out for each different algorithmic strategy in each operator, it is
 a small step to a full cost model. In the last section, cost functions
@@ -1258,7 +1248,6 @@
 a data model (that is, persistent BATs) in the model.
 
 @- Data Definition
[EMAIL PROTECTED]
 We quickly sketch the Prolog clauses that can be used to declare
 an object-oriented data model, mapped on Monet BATs, in the
 Prolog cost model:
@@ -1302,7 +1291,6 @@
 \end{itemize}
 
 @- MIL to Prolog
[EMAIL PROTECTED]
 For each execution order, we give a mil-like Prolog script. The
 first line tpcd() clause instantiates the tpcd data model.
 The other lines correspond 1-1 with MIL assignments statements,
@@ -1328,7 +1316,6 @@
      the standard synonym {\tt table\_attr\_} (underscore appended).}
 
 @- Bugs
[EMAIL PROTECTED]
 We should package this program into a utility that eats MIL
 directly.  It would be an attractive idea to have it callable
 as an extension module from MIL directly.

Index: radix.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/radix.mx,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- radix.mx    11 Jan 2008 10:38:54 -0000      1.6
+++ radix.mx    8 Feb 2008 22:36:06 -0000       1.7
@@ -28,7 +28,6 @@
 are applied in Monet's join processing strategy.
 
 @+ The Memory Story
[EMAIL PROTECTED]
 Computer RAM carries the acronym Random Access Memory, indicating that
 the memory access speed is independent of memory location. While this
 is still (mostly) true, the imbalance in speed improvements between CPU
@@ -73,7 +72,6 @@
 their time on memory cache misses.
 
 @- Optimizing Memory Access during Join
[EMAIL PROTECTED]
 We focus here on improving the memory access performance of the join
 operator in order to gain performance. This is relevant, because the
 most popular main-memory join algorithm is hash-join, which exhibits a
@@ -138,7 +136,6 @@
 This makes radix-cluster even more beneficial on those platforms.
 
 @+ The CPU Story
[EMAIL PROTECTED]
 Modern CPUs are called {\em super-scalar}, by which is meant that the CPU
 has two mechanisms for parallel processing:
 \begin{enumerate}
@@ -211,7 +208,6 @@
 minute, that we solved our first problem, memory access).
 
 @- The CPU optimization problem
[EMAIL PROTECTED]
 Many independent studies show that CPU resource usage during most DBMS loads 
is awful,
 plagued by low prediction rates (and high number of cache misses). This 
indicates that
 typical DBMS software has a nature of being full of if-statements and branches,
@@ -243,7 +239,6 @@
 their effectiveness.
 
 @* Join Processing Optimized for Memory/CPU cost
[EMAIL PROTECTED]
 We now address the issue of optimizing generic join processing for optimal 
usage of
 CPU resources and memory hardware on super-scalar CPUs featuring long 
pipelines and
 out-of-order speculative execution and memory subsystems that consist of deep 
hierarchies
@@ -261,7 +256,6 @@
 tuples than the "smaller" table.
 
 @+ The Monet Approach
[EMAIL PROTECTED]
 In the standard approach this query would be executed in Monet with the 
following MIL statements:
 \begin{verbatim}
 01
@@ -309,7 +303,6 @@
 its hash-table does not fit anymore.
 
 @- The Role of Sorting in improving Memory Access
[EMAIL PROTECTED]
 If the BATs storing the columns of the "larger" table do not fit the memory 
cache anymore,
 the positional joins in the last Y statements of the MIL script will start to 
generate cache
 misses. This is caused by the fact that the OIDs in the tail of the 
res\_larger BATs are
@@ -377,7 +370,6 @@
 absence of hashing allows us to use radix-cluster as radix-sort.
 
 @- Partitioned Hash Join
[EMAIL PROTECTED]
 We now discuss the case that even the smaller\_key BAT with its hash structure 
does not fit the
 smallest cache. What happens then in the join-phase? Since the hash-join 
algorithm exhibits a random
 access pattern, compulsory cache misses will start to appear up to the point 
that each access to
@@ -539,7 +531,6 @@
 \end{verbatim}
 
 @+ The Relational Approach
[EMAIL PROTECTED]
 A cache-conscious join in a relational DBMS would first radix-cluster both the 
smaller and larger table,
 where in the process it would project on just the selected columns. As the 
relational model does not
 separate its algebraic actions by column, as Monet in MIL does, it cannot use 
the technique of type-expansion
@@ -1570,7 +1561,6 @@
 
 
 @+ Radix Cluster
[EMAIL PROTECTED]
 In radix cluster we want to deliver one new BAT that consists
 of a consecutive memory area (like all BATs do) with the tuples
 clustered on a certain radix. To do this correctly in one scan
@@ -2351,7 +2341,6 @@
 }
 
 @+ Phash Join
[EMAIL PROTECTED]
 Joins two clustered inputs with partitioned hash-join. The main innovation of 
this
 implementation is to avoid the (int % mask) and replace it with shifts and 
masks.
 The % takes 40 cycles in modern CPUs while the >>, and, xor take one. Moreover;
@@ -2838,7 +2827,6 @@
 
 
 @+ Radix Decluster
[EMAIL PROTECTED]
 Radix decluster reclusters a BAT that is partially radix-clustered on tail by 
converting
 its non-sorted OID head column into a sorted and densely ascending void 
column. The tail
 itself does not need to contain the partially sorted values; in fact we do not 
even look
@@ -3021,7 +3009,6 @@
 }
 
 @- radix_decluster
[EMAIL PROTECTED]
 intends to improve performance by using a cheaper positional join:
        join(bat[void,oid], bat[void,T])
 instead of

Index: alarm.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/alarm.mx,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- alarm.mx    11 Jan 2008 10:38:54 -0000      1.5
+++ alarm.mx    8 Feb 2008 22:36:06 -0000       1.6
@@ -19,7 +19,6 @@
 @t Timers and Timed Interrupts
 
 @* Introduction
[EMAIL PROTECTED]
 This module handles various signaling/timer functionalities.
 The Monet interface supports two timer commands: {\tt alarm} and {\tt sleep}.
 Their argument is the number of seconds to wait before the timer goes off.

Index: pcre.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/pcre.mx,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- pcre.mx     11 Jan 2008 10:38:54 -0000      1.7
+++ pcre.mx     8 Feb 2008 22:36:06 -0000       1.8
@@ -18,7 +18,6 @@
 @a N. Nes
 @t PCRE - Perl-compatible regular expressions
 @v 0.1
[EMAIL PROTECTED]
 The  PCRE library is a set of functions that implement regular expres-
 sion pattern matching using the same syntax  and  semantics  as  Perl,
 with  just  a  few  differences.  The  current  implementation of PCRE

Index: str.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/str.mx,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- str.mx      11 Jan 2008 10:38:54 -0000      1.8
+++ str.mx      8 Feb 2008 22:36:06 -0000       1.9
@@ -20,7 +20,6 @@
 @t The "string" module
 
 @* Introduction
[EMAIL PROTECTED]
 Strings can be created in many ways. Already in the built-in operations
 each atom can be cast to a string using the str(atom) mil command.
 The string module gives the possibility of construction string as a
@@ -257,7 +256,6 @@
 #endif
 
 @+ UTF-8 Handling
[EMAIL PROTECTED]
 UTF-8 is a way to store Unicode strings in zero-terminated byte sequences, 
which you can e.g.
 strcmp() with old 8-bit Latin-1 strcmp() functions and which then gives the 
same results as doing
 the strcmp() on equivalent Latin-1 and ASCII character strings stored in 
simple one-byte sequences.

Index: sys.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/sys.mx,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- sys.mx      11 Jan 2008 10:38:54 -0000      1.8
+++ sys.mx      8 Feb 2008 22:36:06 -0000       1.9
@@ -58,7 +58,7 @@
         "print a map of all memory that is in use"
 .COMMAND mem_colormap() : void = print_color_map;
         "print a color map of all memory that is in use"
[EMAIL PROTECTED]
+@
 For each 64KB block in the first 3GB of the virtual memory {\tt 
mem\_printmap()} prints a character:
 \begin{verbatim}
 0-9 - thread stack space of thread <num>
@@ -103,7 +103,7 @@
        "get a split-up of how much virtual memory blocks are in use."
 .COMMAND vm_trim(lng maxsize) : void = vm_trim;
        "flush memory maps"
[EMAIL PROTECTED]
+@
 Some explanation of what mem\_usage() and vm\_usage() display:
 \begin{verbatim}
 > mem_usage().print();
@@ -1681,7 +1681,6 @@
 Additional information on the process utilization is given by
 the io command. The following information is obtained.
 
[EMAIL PROTECTED]
 \begin{tabular}{| l| l|}\hline
 maxrss     &the maximum resident set size utilized (in kilobytes).\\
 minflt     &the number of page faults serviced without any I/O\\

Index: profiler.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/profiler.mx,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- profiler.mx 11 Jan 2008 10:38:54 -0000      1.5
+++ profiler.mx 8 Feb 2008 22:36:06 -0000       1.6
@@ -25,7 +25,6 @@
 be incurred when the event records should be produced as well.
 To limit the output to a subset of the events you can set a filter on
 the kind and function name. A convenient filter set is the following
[EMAIL PROTECTED]
 \begin{verbatim}
 setFilter("proc","*");
 setFilter("command","*");
@@ -204,7 +203,6 @@
 
 @-
 
[EMAIL PROTECTED]
 \begin{tabular}{| l| l|}\hline
 maxrss     &the maximum resident set size utilized (in kilobytes).\\
 minflt     &the number of page faults serviced without any I/O\\

Index: logger.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/logger.mx,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- logger.mx   11 Jan 2008 10:38:54 -0000      1.4
+++ logger.mx   8 Feb 2008 22:36:06 -0000       1.5
@@ -18,7 +18,6 @@
 @t Transactions
 @a N. J. Nes
 @v 2.0
[EMAIL PROTECTED]
 @* Introduction
 In the philosophy of MonetDB, transaction management overhead should only
 be paid when necessary. Transaction management is for this purpose 

Index: bat_arith.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/bat_arith.mx,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- bat_arith.mx        11 Jan 2008 10:38:54 -0000      1.4
+++ bat_arith.mx        8 Feb 2008 22:36:06 -0000       1.5
@@ -28,7 +28,7 @@
 @m
 .MODULE bat_arith;
 
[EMAIL PROTECTED]
+@
 \begin{verbatim}
        mel_operation
        @1:     bte, sht, int, wrd, lng, flt, dbl arithmetic type
@@ -58,37 +58,37 @@
 
 @= operations
 @:@1_operation(bte,+,add,,0,2)@
-@:@1_operation(bte,-,sub,,0,1)@
-@:@1_operation(bte,*,mul,1,0,2)@
+@:@1_operation(bte,-,sub,,0,2)@
+@:@1_operation(bte,*,mul,1,0,3)@
 @:@1_operation(bte,/,div,1,1,1)@
 @:@1_operation(bte,%,mod,1,1,0)@
 @:@1_operation(sht,+,add,,0,2)@
-@:@1_operation(sht,-,sub,,0,1)@
-@:@1_operation(sht,*,mul,1,0,2)@
+@:@1_operation(sht,-,sub,,0,2)@
+@:@1_operation(sht,*,mul,1,0,3)@
 @:@1_operation(sht,/,div,1,1,1)@
 @:@1_operation(sht,%,mod,1,1,0)@
 @:@1_operation(int,+,add,,0,2)@
-@:@1_operation(int,-,sub,,0,1)@
-@:@1_operation(int,*,mul,1,0,2)@
+@:@1_operation(int,-,sub,,0,2)@
+@:@1_operation(int,*,mul,1,0,3)@
 @:@1_operation(int,/,div,1,1,1)@
 @:@1_operation(int,%,mod,1,1,0)@
 @:@1_operation(wrd,+,add,,0,2)@
-@:@1_operation(wrd,-,sub,,0,1)@
-@:@1_operation(wrd,*,mul,1,0,2)@
+@:@1_operation(wrd,-,sub,,0,2)@
+@:@1_operation(wrd,*,mul,1,0,3)@
 @:@1_operation(wrd,/,div,1,1,1)@
 @:@1_operation(wrd,%,mod,1,1,0)@
 @:@1_operation(lng,+,add,,0,2)@
-@:@1_operation(lng,-,sub,,0,1)@
-@:@1_operation(lng,*,mul,1,0,2)@
+@:@1_operation(lng,-,sub,,0,2)@
+@:@1_operation(lng,*,mul,1,0,3)@
 @:@1_operation(lng,/,div,1,1,1)@
 @:@1_operation(lng,%,mod,1,1,0)@
 @:@1_operation(flt,+,add,,0,2)@
-@:@1_operation(flt,-,sub,,0,1)@
-@:@1_operation(flt,*,mul,1,0,2)@
+@:@1_operation(flt,-,sub,,0,2)@
+@:@1_operation(flt,*,mul,1,0,3)@
 @:@1_operation(flt,/,div,1,1,1)@
 @:@1_operation(dbl,+,add,,0,2)@
-@:@1_operation(dbl,-,sub,,0,1)@
-@:@1_operation(dbl,*,mul,1,0,2)@
+@:@1_operation(dbl,-,sub,,0,2)@
+@:@1_operation(dbl,*,mul,1,0,3)@
 @:@1_operation(dbl,/,div,1,1,1)@
 @:@1_redefine_OP()@
 @:@1_operation(flt,%,mod,1,1,1,%)@
@@ -227,6 +227,12 @@
 
        if (@6 == 2) 
                bn->tsorted = BATtordered(b);
+       if (@6 == 3) { 
+               if (*v > 0)
+                       bn->tsorted = BATtordered(b);
+               else
+                       bn->tsorted = REVERT_SORTED(BATtordered(b));
+       }
 
        *ret = bn;
        return GDK_SUCCEED;
@@ -240,7 +246,6 @@
                   "[EMAIL PROTECTED]@3_inplace: BAT b must be void-headed.\n");
        /* todo for commutative operators call batval (ie. for * and /) */
 
-       b->tsorted = 0;
        bq = (@1*)Tloc(b,BUNlast(b));
        bp = (@1*)Tloc(b,BUNfirst(b));
        if (vv != @1_nil) {
@@ -261,6 +266,13 @@
 
        if (@6 == 2) 
                b->tsorted = BATtordered(b);
+       if (@6 == 3) { 
+               if (*v > 0)
+                       b->tsorted = BATtordered(b);
+               else
+                       b->tsorted = REVERT_SORTED(BATtordered(b));
+       } else 
+               b->tsorted = 0;
 
        BBPfix(b->batCacheid);
        *ret = b;
@@ -305,8 +317,14 @@
        }
        BATsetcount(bn, bnp-s);
        if (!bn->batDirty) bn->batDirty = TRUE;
-       if (@6) 
+       if (@6 == 2) 
                bn->tsorted = BATtordered(b);
+       if (@6 == 3) { 
+               if (*v > 0)
+                       bn->tsorted = BATtordered(b);
+               else
+                       bn->tsorted = REVERT_SORTED(BATtordered(b));
+       } 
 
        *ret = bn;
        return GDK_SUCCEED;
@@ -321,7 +339,6 @@
        ERRORcheck((b->htype!=TYPE_void),
                   "[EMAIL PROTECTED]@3_inplace: BAT b must be void-headed.\n");
 
-       b->tsorted = 0;
        bq = (@1*)Tloc(b,BUNlast(b));
        bp = (@1*)Tloc(b,BUNfirst(b));
        if (@5 && (vv == 0)) {
@@ -339,8 +356,15 @@
                }
        }
        if (!b->batDirty) b->batDirty = TRUE;
-       if (@6) 
+       if (@6 == 2) 
                b->tsorted = BATtordered(b);
+       if (@6 == 3) { 
+               if (*v > 0)
+                       b->tsorted = BATtordered(b);
+               else
+                       b->tsorted = REVERT_SORTED(BATtordered(b));
+       } else
+               b->tsorted = 0;
 
        BBPfix(b->batCacheid);
        *ret = b;

Index: decimal.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/decimal.mx,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- decimal.mx  11 Jan 2008 10:38:54 -0000      1.6
+++ decimal.mx  8 Feb 2008 22:36:06 -0000       1.7
@@ -20,7 +20,6 @@
 @v 1.0
 
 @+ Introduction
[EMAIL PROTECTED]
 This module introduces the decimal atom to monet. Decimals are intended to
 represent highly complex decimal numbers in a flexible way. Decimal
 numbers consist of a {\em sign}, {\em number} and {\em scale} in the following
@@ -245,7 +244,6 @@
 
 @{
 @+ Implementation
[EMAIL PROTECTED]
 There were three important design aspects for the decimal atom:
 \begin{description}
 \item[fixed or variable-size]
@@ -296,7 +294,6 @@
 #endif /* _DECIMAL_H_ */
 
 @-
[EMAIL PROTECTED]
 Valid numbers have minimally 1 and maximally 16384 digits.  The valid scales 
are between
 [-16384,16384]. There are two special values:
 \begin{description}
@@ -1440,12 +1437,10 @@
 }
 
 @- arithmetic
[EMAIL PROTECTED]
 Computer hardware does not provide built-in support for arbitrarily large 
numbers.
 The iterative algorithms employed here stem directly from Peter's primary 
school.
 
 @- plus and minus
[EMAIL PROTECTED]
 plus and minus algorithms assume positive numbers. Other cases are handled
 as follows:
 \begin{verbatim}

Index: arith.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/arith.mx,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- arith.mx    16 Jan 2008 10:47:53 -0000      1.6
+++ arith.mx    8 Feb 2008 22:36:06 -0000       1.7
@@ -18,7 +18,6 @@
 @a N.J. Nes, P. Boncz, Arjen P. de Vries
 @t The Arithmetics Module
 @* Introduction
[EMAIL PROTECTED]
 This module implements the arithmetic operations on the built-in types,
 {\tt chr}, {\tt bte}, {\tt sht}, {\tt int}, {\tt wrd}, {\tt flt}, {\tt dbl} 
and {\tt lng}.
 All combinations are implemented. Limited combinations are implemented
@@ -107,7 +106,6 @@
        @:mel_isnil_op(str)@
 
 @- comparisons { <, <=, =, !=, >=, > }
[EMAIL PROTECTED]
 The {\tt mel\_comp\_ops} Mx macro implements the mel interface to the
 arithmetic operations. Note that comparison operators with unequal
 operands are already supported in the kernel, but are not nearly as fast,
@@ -149,7 +147,6 @@
        @:mel_comp_ops(str,str)@
 
 @- computation of { +, -, *, /, % }
[EMAIL PROTECTED]
 The {\tt mel\_arith\_ops} Mx macro implements the mel interface to the
 arithmetic operations.  The macro expects four parameters, two input
 atomic types and two result types, the last of which for modulo and
@@ -520,7 +517,7 @@
        return GDK_SUCCEED;
 }
 
[EMAIL PROTECTED]
+@
 The {\tt c\_comp} and {\tt c\_comp\_ops} macros implement the mil comparison
 operations.
 
@@ -687,7 +684,7 @@
        }
        return GDK_SUCCEED;
 }
[EMAIL PROTECTED]
+@
 The {\tt c\_arith\_ops} implement the arithmetic operations on the given type.
 The {\tt c\_arith\_ops} macro gets three arguments, two input types and a
 result type.

Index: xtables.mx
===================================================================
RCS file: /cvsroot/monetdb/MonetDB4/src/modules/plain/xtables.mx,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- xtables.mx  15 Jan 2008 08:24:24 -0000      1.11
+++ xtables.mx  8 Feb 2008 22:36:06 -0000       1.12
@@ -18,7 +18,6 @@
 @a M.L. Kersten, P. Boncz, A.P. de Vries, N.J. Nes -- $Id$
 @v 2.2
 @t Cross Table Module
[EMAIL PROTECTED]
 {\bf Copyright \copyright\ 1996-1999 by Data Distilleries, All Rights Reserved.
 
 No part of this work covered by the copyright hereon may be reproduced or used
@@ -28,7 +27,6 @@
 
 @{
 @+ Document control
[EMAIL PROTECTED]
 (April 2005:) Niels HASH_MAX now indicates the end of the hash chain list 
 (Mar 2005:) Niels removed the histolink accelerator and changed to the grp atom
 
@@ -47,7 +45,6 @@
 @}
 
 @* Introduction
[EMAIL PROTECTED]
 Data mining applications require efficient construction and manipulation
 of cross-tables.
 The Monet kernel already provides for a histogram function over a single BAT.
@@ -61,14 +58,12 @@
 integer id's (as embodied by Monet's void type) is also available.
 
 @+ Algorithms
[EMAIL PROTECTED]
 There are several approaches to build a cross table. The one chosen here
 is aimed at incremental construction, such that re-use of intermediates
 becomes possible. Starting with the first dimension, a BAT is derived to
 represent the various groups, called a {\bf CT BAT} or cross-table BAT.
 
 @- Cross Table (CT)
[EMAIL PROTECTED]
 A cross table is an <oid,oid> BAT where the first (head) denotes a tuple in
 the cross table and the second (tail) marks all identical lists.
 The tail-oids contain group identifiers; that is, {\em this value is equal
@@ -80,13 +75,12 @@
 to the grouping-criterion.
 
 @- going deeper
[EMAIL PROTECTED]
 Successively the subgroups can be identified by modifying the CT BAT or
 to derive a new CT BAT for the subgroups. After all groups have been
 identified this way, a BAT histogram operation can be used to obtain
 the counts of each data cube. Other aggregation operations using the MIL
 set aggregate construct \{X\}(bat) (see the
[EMAIL PROTECTED]<a href="../../../FrontEnds/mil/index.html#mod_3_2_0">MIL 
Reference Manual</a>@)
[EMAIL PROTECTED]<a 
href="_ROOTURL_/MonetDB/Version4/Documentation/mil/index.html#mod_3_2_0">MIL 
Reference Manual</a>@)
 can be used as well; note for instance that histogram == \{count\}(b.reverse).
 
 @* Module Definition
@@ -322,7 +316,6 @@
 }
 
 @+ Core Grouping Algorithms
[EMAIL PROTECTED]
 We use hash-grouping all the way. This implementation employs
 a simple sequential scan through the operands, adding group
 values to a hash-table. This hash-table gives access to the group
@@ -450,7 +443,7 @@
        return bn;
 }
 
[EMAIL PROTECTED]
+@
 The group macro is split along three dimensions:
 \begin{description}
 \item [type:] Type specific implementation for selecting the right


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Monetdb-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-checkins

Reply via email to