klee
Context.h
Go to the documentation of this file.
1//===-- Context.h -----------------------------------------------*- C++ -*-===//
2//
3// The KLEE Symbolic Virtual Machine
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9
10#ifndef KLEE_CONTEXT_H
11#define KLEE_CONTEXT_H
12
13#include "klee/Expr/Expr.h"
14
15namespace klee {
16
18 class Context {
21
24
25 protected:
26 Context(bool _IsLittleEndian, Expr::Width _PointerWidth)
27 : IsLittleEndian(_IsLittleEndian), PointerWidth(_PointerWidth) {}
28
29 public:
31
34
36 static const Context &get();
37
38 bool isLittleEndian() const { return IsLittleEndian; }
39
42 };
43
44} // End klee namespace
45
46#endif /* KLEE_CONTEXT_H */
Context - Helper class for storing global information about a KLEE run.
Definition: Context.h:18
bool isLittleEndian() const
Definition: Context.h:38
Expr::Width PointerWidth
The pointer width of the target architecture.
Definition: Context.h:23
static void initialize(bool IsLittleEndian, Expr::Width PointerWidth)
initialize - Construct the global Context instance.
Definition: Context.cpp:24
Expr::Width getPointerWidth() const
Returns width of the pointer in bits.
Definition: Context.h:41
bool IsLittleEndian
Whether the target architecture is little endian or not.
Definition: Context.h:20
static const Context & get()
get - Return the global singleton instance of the Context.
Definition: Context.cpp:30
Context(bool _IsLittleEndian, Expr::Width _PointerWidth)
Definition: Context.h:26
unsigned Width
The type of an expression is simply its width, in bits.
Definition: Expr.h:97
Definition: main.cpp:291