]> gcc.gnu.org Git - gcc.git/blame - libjava/nogc.cc
* All files: Updated copyright to reflect Cygnus purchase.
[gcc.git] / libjava / nogc.cc
CommitLineData
ee9dd372
TT
1// nogc.cc - Code to implement no GC.
2
7c734b17 3/* Copyright (C) 1998, 1999 Red Hat, Inc.
ee9dd372
TT
4
5 This file is part of libgcj.
6
7This software is copyrighted work licensed under the terms of the
8Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
9details. */
10
11#include <config.h>
12
13#include <stdio.h>
14#include <stdlib.h>
15
27e934d8 16#include <gcj/cni.h>
ee9dd372
TT
17#include <jvm.h>
18
19// Total amount of memory allocated.
20static long total = 0;
21
22void *
23_Jv_AllocObj (jsize size)
24{
25 total += size;
26 return calloc (size, 1);
27}
28
29void *
30_Jv_AllocArray (jsize size)
31{
32 total += size;
33 return calloc (size, 1);
34}
35
36void *
37_Jv_AllocBytes (jsize size)
38{
39 total += size;
40 return calloc (size, 1);
41}
42
43void
44_Jv_RegisterFinalizer (void *, _Jv_FinalizerFunc *)
45{
46 // FIXME: should actually register so that finalizers can be run on
47 // exit.
48}
49
50void
51_Jv_RunFinalizers (void)
52{
53}
54
55void
56_Jv_RunAllFinalizers (void)
57{
58 // FIXME: should still run all finalizers.
59}
60
61void
62_Jv_RunGC (void)
63{
64}
65
66long
67_Jv_GCTotalMemory (void)
68{
69 return total;
70}
71
72long
73_Jv_GCFreeMemory (void)
74{
75 return 0;
76}
77
b8c3c4f0
TT
78void
79_Jv_GCSetInitialHeapSize (size_t size)
80{
81}
82
83void
84_Jv_GCSetMaximumHeapSize (size_t size)
85{
86}
87
ee9dd372
TT
88void
89_Jv_InitGC (void)
90{
91}
This page took 0.079243 seconds and 5 git commands to generate.