* Optimised many of the library functions
[fw/sdcc] / src / z80 / main.c
index 9fb9b075889771a832d36fb49a00e8069083ef81..f27157b28e7b6d9f1f8a26d2e7c7f0a060585c0a 100644 (file)
@@ -294,10 +294,11 @@ _setDefaultOptions (void)
       params is the parameter format
 
    policy format:
-    rs
+    rsp
     where:
       r is 'r' for reentrant, 's' for static functions
       s is 'c' for callee saves, 'r' for caller saves
+      p is 'p' for profiling on, 'x' for profiling off
     examples:
       rr - reentrant, caller saves
    params format:
@@ -313,14 +314,10 @@ _mangleSupportFunctionName(char *original)
 
   if (TARGET_IS_Z80) 
     {
-      if (options.noRegParams) 
-        {
-          sprintf(buffer, "%s_rr_s", original);
-        }
-      else 
-        {
-          sprintf(buffer, "%s_rr_bds", original);
-        }
+      sprintf(buffer, "%s_rr%s_%s", original,
+              options.profile ? "f" : "x",
+              options.noRegParams ? "s" : "bds"
+              );
     }
   else 
     {