ATLAS Offline Software
Loading...
Searching...
No Matches
FPEControlSvc.h
Go to the documentation of this file.
1// This file's extension implies that it's C, but it's really -*- C++ -*-.
2
3/*
4 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
5*/
6
7// $Id: FPEControlSvc.h,v 1.2 2008-09-23 22:00:47 binet Exp $
8
15
16#ifndef ATHENASERVICES_FPECONTROLSVC_H
17#define ATHENASERVICES_FPECONTROLSVC_H
18
19
21#include "GaudiKernel/StatusCode.h"
22#include "Gaudi/Property.h"
23#include "GaudiKernel/IToolSvc.h"
24#include "GaudiKernel/ServiceHandle.h"
25#include <fenv.h>
26
27
51 : public AthService, public IToolSvc::Observer
52{
53public:
55 virtual StatusCode initialize();
56
58 virtual StatusCode finalize();
59
61 virtual void onCreate(const IAlgTool*);
62
63
69 FPEControlSvc( const std::string& name, ISvcLocator* svcloc );
70
71
72private:
74 void setFPU();
75
77 StringArrayProperty m_exceptions;
78
81
83 fenv_t m_env;
84
87
90
93
96
98 std::string m_feSetRounding;
99
101 void prophand (Gaudi::Details::PropertyBase& prop);
102};
103
104#endif // not ATHENASERVICES_FPECONTROLSVC_H
ServiceHandle< IToolSvc > m_toolSvc
Tool service.
int m_disabled
Mask of disabled exceptions.
bool m_haveEnv
Flag that we've retrieved the environment.
std::string m_feSetRounding
flag to decide on rounding mode (for stability tests)
void setFPU()
Set the FPU exception masks from m_enabled and m_disabled.
void prophand(Gaudi::Details::PropertyBase &prop)
Property change handler.
bool m_removeInFinalize
boolean to decide to (not) remove the observer in finalize
StringArrayProperty m_exceptions
Property specifying the desired exception mask.
int m_enabled
Mask of enabled exceptions.
virtual StatusCode finalize()
Standard finalize method.
FPEControlSvc(const std::string &name, ISvcLocator *svcloc)
Constructor.
virtual void onCreate(const IAlgTool *)
Called after each tool has been created.
virtual StatusCode initialize()
Standard initialize method.
fenv_t m_env
The FP environment before we initialize.