source: git/kernel/ncSACache.cc @ 1327a0

fieker-DuValspielwiese
Last change on this file since 1327a0 was ef7b98, checked in by Oleksandr Motsak <motsak@…>, 13 years ago
FIX: fixes due to Sun Studio (removed ncSACache stubs from ncSAMult) From: Oleksandr Motsak <motsak@mathematik.uni-kl.de> git-svn-id: file:///usr/local/Singular/svn/trunk@14155 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 1.6 KB
Line 
1/****************************************
2*  Computer Algebra System SINGULAR     *
3****************************************/
4/***************************************************************
5 *  File:    ncSACache.cc
6 *  Purpose: implementation of special Cache+Hash for Multiplier
7 *  Author:  motsak
8 *  Created:
9 *  Version: $Id$
10 *******************************************************************/
11
12#define MYTEST 0
13
14#if MYTEST
15#define OM_CHECK 4
16#define OM_TRACK 5
17// these settings must be before "mod2.h" in order to work!!!
18#endif
19
20
21#include <kernel/mod2.h>
22
23#ifndef NDEBUG
24#define OUTPUT 1
25#else
26#define OUTPUT 0
27#endif
28
29namespace 
30{
31  static char* m_Typenames[2] = {"lookup", "store"};
32}
33
34#include <kernel/ring.h>
35#include <kernel/p_polys.h>
36
37#include <kernel/ncSACache.h> // for CCacheHash etc classes
38
39
40void CGlobalCacheHash::History(const EHistoryType t, const CGlobalCacheHash::CExponent a, const CGlobalCacheHash::CExponent b, const poly p)
41{
42#if OUTPUT
43  Print("History: GlobalPair, Action: %s", m_Typenames[(int)(t)]);
44  PrintLn();
45  PrintS("Left : "); p_Write(a, GetBasering());
46  PrintS("Right: "); p_Write(b, GetBasering());
47  if( t == MULT_STORE )
48  {
49    PrintS("Result: "); p_Write(p, GetBasering());
50  }
51#endif
52}
53
54
55void  CSpecialPairCacheHash::History(const EHistoryType t, const CSpecialPairCacheHash::CExponent a, const CSpecialPairCacheHash::CExponent b, const poly p)
56{
57#if OUTPUT
58  Print("History: SpecialPair, Action: %s", m_Typenames[(int)(t)]);
59  PrintLn();
60  Print("Left : %d, Right: %d", a, b);
61  PrintLn();
62  if( t == MULT_STORE )
63  {
64    PrintS("Result: "); p_Write(p, GetBasering());
65  }
66#endif
67}
Note: See TracBrowser for help on using the repository browser.