[gs-cvs] rev 8719 - trunk/gs/src

ray at ghostscript.com ray at ghostscript.com
Thu May 8 14:28:30 PDT 2008


Author: ray
Date: 2008-05-08 14:28:30 -0700 (Thu, 08 May 2008)
New Revision: 8719

Modified:
   trunk/gs/src/gsccolor.h
   trunk/gs/src/gxpcmap.c
Log:
Allow some compile time constants that affect performance to be set as
/D compiler flags (via XCFLAGS makefile macro).

MAX_BITMAP_PATTERN_SIZE controls when the clist pattern accumulator is used,
and on machines with a decent amount of RAM, the default of 1 Mb is too
small and causes the slower clist method to be used too often. Setting this
to 32 Mb is probably better on hosts.

The GS_CLIENT_COLOR_MAX_COMPONENTS default of 252 is needed for Adobe CPSI
compatibility and for RIPS that want to use a large number of DeviceN
colorants, but this increases the size of some allocations and slows down
performance and is much too large for printers. Setting this to 6 or 8 is
probably plenty.


Modified: trunk/gs/src/gsccolor.h
===================================================================
--- trunk/gs/src/gsccolor.h	2008-05-08 20:09:32 UTC (rev 8718)
+++ trunk/gs/src/gsccolor.h	2008-05-08 21:28:30 UTC (rev 8719)
@@ -31,7 +31,9 @@
  * hexachrome DeviceN color spaces.  It is currently set to the same
  * value as Adobe CPSI can handle 
  */
-#define GS_CLIENT_COLOR_MAX_COMPONENTS (252)
+#ifndef GS_CLIENT_COLOR_MAX_COMPONENTS		/* Allow override with XCFLAGS */
+#  define GS_CLIENT_COLOR_MAX_COMPONENTS (252)
+#endif
 
 /* Paint (non-Pattern) colors */
 typedef struct gs_paint_color_s {

Modified: trunk/gs/src/gxpcmap.c
===================================================================
--- trunk/gs/src/gxpcmap.c	2008-05-08 20:09:32 UTC (rev 8718)
+++ trunk/gs/src/gxpcmap.c	2008-05-08 21:28:30 UTC (rev 8719)
@@ -173,7 +173,9 @@
 {
 }
 
-#define MAX_BITMAP_PATTERN_SIZE (1024*1024)
+#ifndef MAX_BITMAP_PATTERN_SIZE		/* Allow override with XCFLAGS */
+#  define MAX_BITMAP_PATTERN_SIZE (1024*1024)
+#endif
 
 /* Allocate a pattern accumulator, with an initial refct of 0. */
 gx_device_forward *



More information about the gs-cvs mailing list