mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-17 01:41:17 -10:00
Compare commits
64
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3bed938706 | ||
|
|
648d57f953 | ||
|
|
b074521b4a | ||
|
|
0ff0e4a3ab | ||
|
|
4f2fdce3f1 | ||
|
|
53fe2fcc6c | ||
|
|
6709c2a45c | ||
|
|
7acf134f87 | ||
|
|
fa548405b0 | ||
|
|
843c848204 | ||
|
|
497ce22fc6 | ||
|
|
653ec37674 | ||
|
|
5b3788b38f | ||
|
|
abdd0768e4 | ||
|
|
ef815643d6 | ||
|
|
6a2bf11ad1 | ||
|
|
0ba544bb3e | ||
|
|
844802dcbc | ||
|
|
f280fc8948 | ||
|
|
ae7c481271 | ||
|
|
96fa9c4caa | ||
|
|
685020351f | ||
|
|
b0a27d618e | ||
|
|
863a2facac | ||
|
|
137be5c4c6 | ||
|
|
a6d6ba0a8b | ||
|
|
0d2f55c479 | ||
|
|
22eed26360 | ||
|
|
18fb56ed20 | ||
|
|
7c13ce3a30 | ||
|
|
9e93acc48d | ||
|
|
831460d7f0 | ||
|
|
597edc180d | ||
|
|
9a707655f0 | ||
|
|
5919e994aa | ||
|
|
b3088be180 | ||
|
|
96175ef31f | ||
|
|
afae051ab2 | ||
|
|
532243548b | ||
|
|
e97fb5eae4 | ||
|
|
1c61ec2e9c | ||
|
|
8054b7da1d | ||
|
|
0984f3e0df | ||
|
|
29b41af285 | ||
|
|
68f1541bbe | ||
|
|
90df5a0520 | ||
|
|
ab327e3cf4 | ||
|
|
bc48f07609 | ||
|
|
577e6a119c | ||
|
|
3c4cdb8b91 | ||
|
|
de58d722d5 | ||
|
|
97481dc4a6 | ||
|
|
430712a419 | ||
|
|
d1bd93f4bb | ||
|
|
7093959bb4 | ||
|
|
008f986fbd | ||
|
|
b02372594e | ||
|
|
ea352f90cc | ||
|
|
ac5d54f6b1 | ||
|
|
163687fa8c | ||
|
|
263682463b | ||
|
|
118ffd52f7 | ||
|
|
9f0d7641dd | ||
|
|
0e8b8ba063 |
No files matched your search
@@ -9,6 +9,7 @@ configure.ac crlf=input
|
||||
*.il crlf
|
||||
|
||||
.gitattributes crlf
|
||||
ChangeLog crlf
|
||||
*akefile* crlf
|
||||
*.sources crlf
|
||||
|
||||
|
||||
+3
-4
@@ -23,6 +23,7 @@
|
||||
*.tlb
|
||||
*.tlh
|
||||
*.bak
|
||||
*.[Cc]ache
|
||||
*.ilk
|
||||
*.log
|
||||
*.lib
|
||||
@@ -43,8 +44,6 @@ Ankh.NoLoad
|
||||
_ReSharper*/
|
||||
*.resharper
|
||||
[Tt]est[Rr]esult*
|
||||
*.orig
|
||||
*.rej
|
||||
|
||||
# NuGet packages
|
||||
!.nuget/*
|
||||
@@ -123,7 +122,7 @@ docs/perlmod*
|
||||
compile
|
||||
mono.h
|
||||
mono-*.tar.*
|
||||
mono.spec
|
||||
mono-core.spec
|
||||
tmpinst-dir.stamp
|
||||
msvc/scripts/inputs/
|
||||
extensions-config.h
|
||||
|
||||
+7
-7
@@ -10,6 +10,9 @@
|
||||
[submodule "external/debian-snapshot"]
|
||||
path = external/debian-snapshot
|
||||
url = git://github.com/directhex/mono-snapshot.git
|
||||
[submodule "external/entityframework"]
|
||||
path = external/entityframework
|
||||
url = git://github.com/mono/entityframework.git
|
||||
[submodule "external/rx"]
|
||||
path = external/rx
|
||||
url = git://github.com/mono/rx.git
|
||||
@@ -17,19 +20,16 @@
|
||||
[submodule "external/ikvm"]
|
||||
path = external/ikvm
|
||||
url = git://github.com/mono/ikvm-fork.git
|
||||
[submodule "external/Lucene.Net"]
|
||||
path = external/Lucene.Net
|
||||
url = git://github.com/mono/lucene.net.git
|
||||
[submodule "external/ikdasm"]
|
||||
path = external/ikdasm
|
||||
url = git://github.com/mono/ikdasm.git
|
||||
[submodule "external/referencesource"]
|
||||
path = external/referencesource
|
||||
url = git://github.com/mono/referencesource
|
||||
url = https://github.com/mono/referencesource
|
||||
branch = mono
|
||||
[submodule "external/reference-assemblies"]
|
||||
path = external/binary-reference-assemblies
|
||||
url = git://github.com/mono/reference-assemblies.git
|
||||
[submodule "external/Lucene.Net.Light"]
|
||||
path = external/Lucene.Net.Light
|
||||
url = git://github.com/mono/Lucene.Net.Light.git
|
||||
[submodule "external/nunit-lite"]
|
||||
path = external/nunit-lite
|
||||
url = git://github.com/mono/NUnitLite.git
|
||||
@@ -0,0 +1,3 @@
|
||||
Miguel de Icaza ([email protected])
|
||||
Paolo Molaro ([email protected])
|
||||
Dietmar Maurer ([email protected])
|
||||
@@ -8,8 +8,8 @@ For comments, corrections and updates, please contact [email protected]
|
||||
|
||||
Parts of Mono are dual licensed, they are available to the
|
||||
public in GPL or LGPL forms, but we also offer those pieces
|
||||
under commercial terms from Xamarin for the cases where the
|
||||
GPL and the LGPL are not suitable.
|
||||
under commercial terms from Xamarin for the cases wher the GPL
|
||||
and the LGPL are not suitable.
|
||||
|
||||
We have tried to pick the licenses that will maximize adoption
|
||||
of Mono, so we tend to use the MIT X11 or LGPL liceses.
|
||||
|
||||
+23
-14
@@ -5,15 +5,23 @@ AM_CFLAGS = $(WERROR_CFLAGS)
|
||||
MONOTOUCH_SUBDIRS = $(libgc_dir) eglib/src mono
|
||||
|
||||
if CROSS_COMPILING
|
||||
SUBDIRS = po $(libgc_dir) eglib mono $(ikvm_native_dir) support data runtime scripts man samples msvc $(docs_dir) acceptance-tests
|
||||
SUBDIRS = po $(libgc_dir) eglib mono $(ikvm_native_dir) support data runtime scripts man samples msvc $(docs_dir)
|
||||
# Keep in sync with SUBDIRS
|
||||
## 'tools' is not normally built
|
||||
DIST_SUBDIRS = m4 po $(libgc_dir) eglib mono ikvm-native support data runtime scripts man samples tools msvc docs acceptance-tests
|
||||
DIST_SUBDIRS = m4 po $(libgc_dir) eglib mono ikvm-native support data runtime scripts man samples tools msvc docs
|
||||
else
|
||||
SUBDIRS = po $(libgc_dir) eglib mono $(ikvm_native_dir) support data runtime scripts man samples msvc $(docs_dir) acceptance-tests
|
||||
if ONLY_MONOTOUCH
|
||||
SUBDIRS = $(MONOTOUCH_SUBDIRS) runtime
|
||||
else
|
||||
if ONLY_XAMMAC
|
||||
SUBDIRS = $(libgc_dir) eglib/src mono runtime
|
||||
else
|
||||
SUBDIRS = po $(libgc_dir) eglib mono $(ikvm_native_dir) support data runtime scripts man samples msvc $(docs_dir)
|
||||
# Keep in sync with SUBDIRS
|
||||
## 'tools' is not normally built
|
||||
DIST_SUBDIRS = m4 po $(libgc_dir) eglib mono ikvm-native support data runtime scripts man samples tools msvc docs acceptance-tests
|
||||
DIST_SUBDIRS = m4 po $(libgc_dir) eglib mono ikvm-native support data runtime scripts man samples tools msvc docs
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
all: update_submodules
|
||||
@@ -25,14 +33,15 @@ update_submodules:
|
||||
.PHONY: update_submodules
|
||||
|
||||
EXTRA_DIST= \
|
||||
README.md \
|
||||
LICENSE \
|
||||
autogen.sh \
|
||||
mkinstalldirs \
|
||||
mono-uninstalled.pc.in \
|
||||
winconfig.h \
|
||||
code_of_conduct.md \
|
||||
external
|
||||
README.md \
|
||||
LICENSE \
|
||||
autogen.sh \
|
||||
build-mingw32.sh \
|
||||
mkinstalldirs \
|
||||
mono-uninstalled.pc.in \
|
||||
winconfig.h \
|
||||
mono-core.spec \
|
||||
external
|
||||
|
||||
DISTCHECK_CONFIGURE_FLAGS = EXTERNAL_MCS=false EXTERNAL_RUNTIME=false
|
||||
|
||||
@@ -43,7 +52,7 @@ dist-hook:
|
||||
d=`cd $(distdir)/mcs && pwd`; cd $(mcs_topdir) && $(MAKE) distdir=$$d dist-recursive
|
||||
rm -rf `find $(top_distdir)/external -path '*\.git'`
|
||||
rm -f `find $(top_distdir)/external -path '*\.exe'`
|
||||
rm -f `find $(top_distdir)/external -path '*\.dll' -not -path '*/binary-reference-assemblies/*'`
|
||||
rm -f `find $(top_distdir)/external -path '*\.dll' -not -path '*/binary-reference-assemblies/v4\.0*'`
|
||||
cp mcs/class/lib/basic/System.Configuration.dll mcs/class/lib/monolite/
|
||||
cp mcs/class/lib/basic/System.Security.dll mcs/class/lib/monolite/
|
||||
# Disable this for now because it is very slow and causes wrench to timeout:
|
||||
@@ -57,7 +66,7 @@ DISTCLEANFILES= mono-uninstalled.pc
|
||||
mcslib = $(mcs_topdir)/class/lib
|
||||
monolite = $(mcslib)/monolite
|
||||
mono_corlib_version = $(shell sed -n "s/\#define MONO_CORLIB_VERSION //p" $(srcdir)/mono/metadata/appdomain.c)
|
||||
monolite_url = http://download.mono-project.com/monolite/monolite-$(mono_corlib_version)-latest.tar.gz
|
||||
monolite_url = http://storage.bos.xamarin.com/mono-dist-master/latest/monolite-$(mono_corlib_version)-latest.tar.gz
|
||||
.PHONY: get-monolite-latest
|
||||
get-monolite-latest:
|
||||
-rm -fr $(mcslib)/monolite-*
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
Release notes for Mono are hosted on the web, please see:
|
||||
|
||||
http://www.mono-project.com/docs/about-mono/releases/
|
||||
http://www.go-mono.com/archive/VERSION
|
||||
|
||||
Where version is the version of this Mono package, for example:
|
||||
|
||||
http://www.go-mono.com/archive/1.1.9
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
Mono is a software platform designed to allow developers to easily
|
||||
create cross platform applications. It is an open source
|
||||
implementation of Microsoft's .NET Framework based on the ECMA
|
||||
standards for C# and the Common Language Runtime.
|
||||
|
||||
[](https://gitter.im/mono/mono?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
||||
Mono is a software platform designed to allow developers to easily create cross platform applications.
|
||||
It is an open source implementation of Microsoft's .NET Framework based on the ECMA standards for C# and the Common Language Runtime.
|
||||
|
||||
1. [Compilation and Installation](#compilation-and-installation)
|
||||
2. [Using Mono](#using-mono)
|
||||
@@ -11,34 +7,23 @@ standards for C# and the Common Language Runtime.
|
||||
4. [Contributing to Mono](#contributing-to-mono)
|
||||
5. [Reporting bugs](#reporting-bugs)
|
||||
6. [Configuration Options](#configuration-options)
|
||||
7. [Working with Submodules](#working-with-submodules)
|
||||
|
||||
**Build Status**
|
||||
|
||||
Officially supported architectures:
|
||||
|
||||
| debian-amd64 | debian-i386 | debian-armel | debian-armhf | windows-amd64 |
|
||||
|-------------------------|------------------------|-------------------------|-------------------------|---------------------------|
|
||||
| [![debian-amd64][1]][2] | [![debian-i386][3]][4] | [![debian-armel][5]][6] | [![debian-armhf][7]][8] | [![windows-amd64][9]][10] |
|
||||
|
||||
Community supported architectures:
|
||||
|
||||
| centos-s390x |
|
||||
|---------------------------|
|
||||
| [![centos-s390x][11]][12] |
|
||||
| debian-amd64 | debian-i386 | debian-ppc64el | centos-s390x | windows-amd64 |
|
||||
|:-----------------------:|:----------------------:|:-------------------------:|:-----------------------:|:-------------------------:|
|
||||
| [![debian-amd64][1]][2] | [![debian-i386][3]][4] | [![debian-ppc64el][5]][6] | [![centos-s390x][7]][8] | [![windows-amd64][9]][10] |
|
||||
|
||||
[1]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-amd64/badge/icon
|
||||
[2]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-amd64/
|
||||
[3]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-i386/badge/icon
|
||||
[4]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-i386/
|
||||
[5]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-armel/badge/icon
|
||||
[6]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-armel/
|
||||
[7]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-armhf/badge/icon
|
||||
[8]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-armhf/
|
||||
[5]: http://jenkins.mono-project.com/job/test-mono-mainline-communityarchitectures/label=debian-ppc64el/badge/icon
|
||||
[6]: http://jenkins.mono-project.com/job/test-mono-mainline-communityarchitectures/label=debian-ppc64el/
|
||||
[7]: http://jenkins.mono-project.com/job/test-mono-mainline-communityarchitectures/label=centos-s390x/badge/icon
|
||||
[8]: http://jenkins.mono-project.com/job/test-mono-mainline-communityarchitectures/label=centos-s390x/
|
||||
[9]: https://ci.appveyor.com/api/projects/status/1e61ebdfpbiei58v/branch/master?svg=true
|
||||
[10]: https://ci.appveyor.com/project/ajlennon/mono-817/branch/master
|
||||
[11]: https://jenkins.mono-project.com/job/z/label=centos-s390x/badge/icon
|
||||
[12]: https://jenkins.mono-project.com/job/z/label=centos-s390x
|
||||
|
||||
Compilation and Installation
|
||||
============================
|
||||
@@ -70,7 +55,7 @@ which contains just enough to run the 'mcs' compiler. You do this with:
|
||||
This will download and place the files appropriately so that you can then
|
||||
just run:
|
||||
|
||||
make
|
||||
make EXTERNAL_MCS=${PWD}/mcs/class/lib/monolite/basic.exe
|
||||
|
||||
The build will then use the files downloaded by `make get-monolite-latest`.
|
||||
|
||||
@@ -80,7 +65,8 @@ Testing and Installation
|
||||
You can run the mono and mcs test suites with the command: `make check`.
|
||||
|
||||
Expect to find a few test suite failures. As a sanity check, you
|
||||
can compare the failures you got with [https://jenkins.mono-project.com/](https://jenkins.mono-project.com/).
|
||||
can compare the failures you got with [https://wrench.mono-project.com/Wrench/](https://wrench.mono-project.com/Wrench/)
|
||||
and [http://jenkins.mono-project.com/](http://jenkins.mono-project.com/).
|
||||
|
||||
You can now install mono with: `make install`
|
||||
|
||||
@@ -144,63 +130,60 @@ runtime as an embedded library.
|
||||
|
||||
* `scripts/` - Scripts used to invoke Mono and the corresponding program.
|
||||
|
||||
* `../olive/` - Incubation code from [Olive](https://github.com/mono/olive).
|
||||
|
||||
* If the directory ../olive is present (as an
|
||||
independent checkout) from the Mono module, that
|
||||
directory is automatically configured to share the
|
||||
same prefix than this module gets.
|
||||
|
||||
Contributing to Mono
|
||||
====================
|
||||
|
||||
Before submitting changes to Mono, please review the [contribution
|
||||
guidelines](http://www.mono-project.com/community/contributing/).
|
||||
Please pay particular attention to the [Important
|
||||
Rules](http://www.mono-project.com/community/contributing/#important-rules)
|
||||
section.
|
||||
Before submitting changes to Mono, please review the [contribution guidelines](http://www.mono-project.com/community/contributing/).
|
||||
Please pay particular attention to the [Important Rules](http://www.mono-project.com/community/contributing/#important-rules) section.
|
||||
|
||||
Reporting bugs
|
||||
==============
|
||||
|
||||
To submit bug reports, please use [Xamarin's
|
||||
Bugzilla](https://bugzilla.xamarin.com/)
|
||||
To submit bug reports, please use [Xamarin's Bugzilla](https://bugzilla.xamarin.com/)
|
||||
|
||||
Please use the search facility to ensure the same bug hasn't already
|
||||
been submitted and follow our
|
||||
[guidelines](http://www.mono-project.com/community/bugs/make-a-good-bug-report/)
|
||||
been submitted and follow our [guidelines](http://www.mono-project.com/community/bugs/make-a-good-bug-report/)
|
||||
on how to make a good bug report.
|
||||
|
||||
Configuration Options
|
||||
=====================
|
||||
|
||||
The following are the configuration options that someone building Mono
|
||||
might want to use:
|
||||
The following are the configuration options that someone
|
||||
building Mono might want to use:
|
||||
|
||||
* `--with-sgen=yes,no` - Generational GC support: Used to enable or
|
||||
disable the compilation of a Mono runtime with the SGen garbage
|
||||
collector.
|
||||
* `--with-sgen=yes,no` - Generational GC support: Used to enable or disable the
|
||||
compilation of a Mono runtime with the SGen garbage collector.
|
||||
|
||||
* On platforms that support it, after building Mono, you will have
|
||||
both a `mono` binary and a `mono-sgen` binary. `mono` uses Boehm,
|
||||
while `mono-sgen` uses the Simple Generational GC.
|
||||
both a `mono` binary and a `mono-sgen` binary. `mono` uses Boehm, while
|
||||
`mono-sgen` uses the Simple Generational GC.
|
||||
|
||||
* `--with-gc=[included, boehm, none]` - Selects the default Boehm
|
||||
garbage collector engine to use.
|
||||
* `--with-gc=[included, boehm, none]` - Selects the default Boehm garbage
|
||||
collector engine to use.
|
||||
|
||||
* *included*: (*slightly modified Boehm GC*) This is the default
|
||||
value for the Boehm GC, and it's the most feature complete, it will
|
||||
allow Mono to use typed allocations and support the debugger.
|
||||
* *included*: (*slighty modified Boehm GC*)
|
||||
This is the default value for the Boehm GC, and it's
|
||||
the most feature complete, it will allow Mono
|
||||
to use typed allocations and support the debugger.
|
||||
|
||||
* *boehm*: This is used to use a system-install Boehm GC, it is
|
||||
useful to test new features available in Boehm GC, but we do not
|
||||
recommend that people use this, as it disables a few features.
|
||||
* *boehm*:
|
||||
This is used to use a system-install Boehm GC,
|
||||
it is useful to test new features available in
|
||||
Boehm GC, but we do not recommend that people
|
||||
use this, as it disables a few features.
|
||||
|
||||
* *none*:
|
||||
Disables the inclusion of a garbage collector.
|
||||
|
||||
* This defaults to `included`.
|
||||
|
||||
* `--with-cooperative-gc`
|
||||
|
||||
* If you pass this flag the Mono runtime is configured to only use
|
||||
the cooperative mode of the garbage collector. If you do not pass
|
||||
this flag, then you can control at runtime the use of the
|
||||
cooperative GC mode by setting the `MONO_ENABLE_COOP` flag.
|
||||
|
||||
* `--with-tls=__thread,pthread`
|
||||
|
||||
* Controls how Mono should access thread local storage,
|
||||
@@ -426,10 +409,8 @@ cycle.
|
||||
multiple CPUs to do its work. This helps performance
|
||||
on multi-CPU machines as the work is divided across CPUS.
|
||||
|
||||
* This option is not currently the default on OSX
|
||||
as it runs into issues there.
|
||||
|
||||
* This option only applies to the Boehm GC.
|
||||
* This option is not currently the default as we have
|
||||
not done much testing with Mono.
|
||||
|
||||
* `--enable-dtrace`
|
||||
|
||||
@@ -455,53 +436,3 @@ http://code.google.com/p/nativeclient/
|
||||
|
||||
* Currently this is used with Mono's AOT engine as
|
||||
Native Client does not support JIT engines yet.
|
||||
|
||||
Working With Submodules
|
||||
=======================
|
||||
|
||||
Mono references several external git submodules, for example
|
||||
a fork of Microsoft's reference source code that has been altered
|
||||
to be suitable for use with the Mono runtime.
|
||||
|
||||
This section describes how to use it.
|
||||
|
||||
An initial clone should be done recursively so all submodules will also be
|
||||
cloned in a single pass:
|
||||
|
||||
$ git clone --recursive git@github.com:mono/mono
|
||||
|
||||
Once cloned, submodules can be updated to pull down the latest changes.
|
||||
This can also be done after an initial non-recursive clone:
|
||||
|
||||
$ git submodule update --init --recursive
|
||||
|
||||
To pull external changes into a submodule:
|
||||
|
||||
$ cd <submodule>
|
||||
$ git pull origin <branch>
|
||||
$ cd <top-level>
|
||||
$ git add <submodule>
|
||||
$ git commit
|
||||
|
||||
By default, submodules are detached because they point to a specific commit.
|
||||
Use `git checkout` to move back to a branch before making changes:
|
||||
|
||||
$ cd <submodule>
|
||||
$ git checkout <branch>
|
||||
# work as normal; the submodule is a normal repo
|
||||
$ git commit/push new changes to the repo (submodule)
|
||||
|
||||
$ cd <top-level>
|
||||
$ git add <submodule> # this will record the new commits to the submodule
|
||||
$ git commit
|
||||
|
||||
To switch the repo of a submodule (this should not be a common or normal thing
|
||||
to do at all), first edit `.gitmodules` to point to the new location, then:
|
||||
|
||||
$ git submodule sync -- <path of the submodule>
|
||||
$ git submodule update --recursive
|
||||
$ git checkout <desired new hash or branch>
|
||||
|
||||
The desired output diff is a change in `.gitmodules` to reflect the
|
||||
change in the remote URL, and a change in /<submodule> where you see
|
||||
the desired change in the commit hash.
|
||||
+120
@@ -0,0 +1,120 @@
|
||||
README.vsnet Last updated: 2006-02-01
|
||||
|
||||
|
||||
SVN includes a Visual Studio .NET 2005 solution, mono.sln, and some
|
||||
projects files to build most of the unmanaged parts in Mono.
|
||||
|
||||
The "mono.sln" solution file contains the VC projects files for:
|
||||
|
||||
* Embedded Samples
|
||||
* test-invoke.vcproj
|
||||
* test-metadata.vcproj
|
||||
* teste.vcproj
|
||||
* Libraries
|
||||
* libgc.vcproj
|
||||
* libmono.vcproj
|
||||
* Tools
|
||||
* genmdesc.vcproj
|
||||
* monoburg.vcproj
|
||||
* monodiet.vcproj
|
||||
* monodis.vcproj
|
||||
* monograph.vcproj
|
||||
* pedump.vcproj
|
||||
* mono.vcproj
|
||||
|
||||
|
||||
REQUIREMENTS
|
||||
|
||||
* A working (i.e. where you could succesfully build mono) cygwin
|
||||
(http://www.cygwin.com/) setup! This is required to:
|
||||
* generate some files (via monoburg and genmdesc);
|
||||
* build the class libraries; and
|
||||
* test for regressions.
|
||||
|
||||
* Visual Studio .NET 2005. Previous Visual Studio versions may work or
|
||||
requires, hopefully minimal, changes.
|
||||
|
||||
* VSDependencies.zip must be decompressed under the /mono/ directory
|
||||
(otherwise you will need to edit all the projects files). This file can
|
||||
be downloaded from http://www.go-mono.com/archive/VSDependencies.zip
|
||||
|
||||
|
||||
LOCAL CHANGES
|
||||
|
||||
Sadly solution/projects files aren't easy to move from computers to
|
||||
computers (well unless everyone follow the same naming convention) so
|
||||
you'll likely have to changes some options in order to compile the
|
||||
solution.
|
||||
|
||||
* each executed assembly (i.e. the EXE) must be able to find a
|
||||
working mscorlib.dll (and all the other required assemblies).
|
||||
This can be done in different ways. My preference is to use the
|
||||
project "properties pages" in the "Configuration Properties
|
||||
\Debugging\Environment" options and set MONO_PATH to the class
|
||||
libraries directory build by cygwin (local) or on Linux
|
||||
(remote).
|
||||
|
||||
e.g. MONO_PATH=z:\svn\mcs\class\lib\default\
|
||||
allows me to use the class libs build under Linux, while
|
||||
MONO_PATH=C:\cygwin\opt\mono\lib\mono\1.0
|
||||
use the one built from cygwin (after a make install)
|
||||
|
||||
Some useful informations to adapt the solution/project files...
|
||||
|
||||
* My cygwin root dir is: c:\cygwin\
|
||||
* My username is: poupou
|
||||
* My mono install prefix is: /opt/mono
|
||||
|
||||
|
||||
BUILDING
|
||||
|
||||
Once everything is installed (and edited) you can right-click on the
|
||||
"mono" solution (in the "Solution Explorer"), select "Clean
|
||||
Solution" (for the first time) then "Build Solution".
|
||||
|
||||
|
||||
KNOWN ISSUES
|
||||
|
||||
[1] Most, BUT NOT ALL, the regressions tests pass under this build. The
|
||||
failures seems limited to some mathematical differences and to code
|
||||
relying on the stack walking functions. The hacks to replace the GCC
|
||||
functions (__builtin_frame_address and __builtin_return_address) are
|
||||
incomplete;
|
||||
|
||||
[2] The solution doesn't provide complete (i.e. from scratch) build. It
|
||||
requires a working cygwin environment to create some files (e.g. via
|
||||
genmdesc, monoburg). This isn't so bad as without cygwin you wouldn't be
|
||||
able to test Mono properly (see REQUIREMENTS);
|
||||
|
||||
[3] Only the Debug target is configured properly (that would be easy to
|
||||
fix, but would require turning off some optimizations like omitting
|
||||
stack frames). Anyway there are other issues [1] to fix before switching
|
||||
to Release and IMHO the _biggest_ advantage to VS.NET is it's debugger/
|
||||
debugging tools;
|
||||
|
||||
[4] The C compiler emits _lots_ of warning during compilation. Some
|
||||
warnings have been turned off for some projects (there was so much that
|
||||
it slowed down compilation). You can bring them back (or hide more of
|
||||
them) using the project "properties pages" windows, "Configuration
|
||||
Properties\C/C++\Advanced\Disable Specific Warnings";
|
||||
|
||||
[5] Visual Studio 2005 should have all the latest header files required,
|
||||
but if not (or if you're using an older version of VS) then install MS
|
||||
Platform SDK (Windows Server 2003 is the latest) to ensure you have the
|
||||
latest Windows header files. You can download it from:
|
||||
http://www.microsoft.com/msdownload/platformsdk/sdkupdate/psdk-full.htm
|
||||
|
||||
[6] Not everyone has VS.NET so it is possible you may have to add some
|
||||
(new) files to the build from time to time. See "more informations" for
|
||||
reporting those changes.
|
||||
|
||||
[7] Probably a lot more I didn't discover... or has changed since.
|
||||
|
||||
|
||||
MORE INFORMATION
|
||||
|
||||
Please email <[email protected]> if you have any problem
|
||||
and/or if there's something wrong/missing in the instructions.
|
||||
|
||||
An online version of this file is available at
|
||||
http://www.mono-project.com/Compiling_Mono_VSNET
|
||||
@@ -1,6 +0,0 @@
|
||||
Makefile.in
|
||||
Makefile
|
||||
*.exe
|
||||
*.dll
|
||||
*.mdb
|
||||
coreclr-testlist.txt
|
||||
@@ -1,14 +0,0 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Reflection;
|
||||
|
||||
namespace System.Runtime.Loader
|
||||
{
|
||||
public static class AssemblyExtensions
|
||||
{
|
||||
public static Type[] GetTypes(this Assembly assembly)
|
||||
{
|
||||
return assembly.GetTypes ();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,41 +0,0 @@
|
||||
using System;
|
||||
using System.IO;
|
||||
using System.Reflection;
|
||||
|
||||
namespace System.Runtime.Loader
|
||||
{
|
||||
public abstract class AssemblyLoadContext
|
||||
{
|
||||
protected abstract Assembly Load(AssemblyName assemblyName);
|
||||
|
||||
protected Assembly LoadFromAssemblyPath(string assemblyPath)
|
||||
{
|
||||
if (assemblyPath == null)
|
||||
throw new ArgumentNullException("assemblyPath");
|
||||
|
||||
if (!Path.IsPathRooted(assemblyPath))
|
||||
throw new ArgumentException("Gimme an absolute path " + assemblyPath + " XXX " + Path.GetPathRoot(assemblyPath), "assemblyPath");
|
||||
|
||||
return Assembly.LoadFrom (assemblyPath);
|
||||
}
|
||||
|
||||
public Assembly LoadFromAssemblyName(AssemblyName assemblyName)
|
||||
{
|
||||
// AssemblyName is mutable. Cache the expected name before anybody gets a chance to modify it.
|
||||
string requestedSimpleName = assemblyName.Name;
|
||||
|
||||
Assembly assembly = Load(assemblyName);
|
||||
if (assembly == null)
|
||||
throw new FileLoadException("File not found", requestedSimpleName);
|
||||
|
||||
return assembly;
|
||||
}
|
||||
|
||||
public static AssemblyName GetAssemblyName(string assemblyPath)
|
||||
{
|
||||
if (!File.Exists (assemblyPath))
|
||||
throw new Exception ("file not found");
|
||||
return new AssemblyName (Path.GetFileName (assemblyPath));
|
||||
}
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large.
Load diff
@@ -1,14 +0,0 @@
|
||||
This directory contains acceptance tests, handled by optional non git submodule based submodules. Run the tests via "make check-full" (there are also targets for individual test suites).
|
||||
|
||||
The SUBMODULES.json file stores information about the submodules, and make targets are used to check out submodules, check their versions, and update the submodule information.
|
||||
|
||||
By convention, submodules repositories are at the same level as the mono repository.
|
||||
|
||||
Make targets available:
|
||||
|
||||
make check-<module> - Checks whenever <module> is checked out and matches the version in the info file.
|
||||
make reset-<module> - Clones <module>if neccesary and checks out the revision specified in the info file.
|
||||
make bump-<module> - Updates the revision stored in the info file for <module>.
|
||||
make bump-current-<module> - Updates the revision stored in the info file for <module> to the current revision.
|
||||
make commit-bump-<module> - Same as make bump-<module>, but commits the change.
|
||||
make commit-bump-current-<module> - Same as make bump-current-<module>, but commits the change.
|
||||
@@ -1,26 +0,0 @@
|
||||
[
|
||||
{
|
||||
"name": "roslyn",
|
||||
"url": "git://github.com/dotnet/roslyn.git",
|
||||
"rev": "322bd5b2bbf07df6a67de35cbcb2365484412f70",
|
||||
"remote-branch": "origin/master",
|
||||
"branch": "master",
|
||||
"directory": "roslyn"
|
||||
},
|
||||
{
|
||||
"name": "coreclr",
|
||||
"url": "git://github.com/mono/coreclr.git",
|
||||
"rev": "96cf61f96b42cf9d013e641609cb7787f6e3a71f",
|
||||
"remote-branch": "origin/mono",
|
||||
"branch": "mono",
|
||||
"directory": "coreclr"
|
||||
},
|
||||
{
|
||||
"name": "ms-test-suite",
|
||||
"url": "[email protected]:xamarin/ms-test-suite.git",
|
||||
"rev": "8eb26bd72a38e2c78675db45b13e89237dbdf4f2",
|
||||
"remote-branch": "origin/master",
|
||||
"branch": "master",
|
||||
"directory": "ms-test-suite"
|
||||
}
|
||||
]
|
||||
@@ -1,159 +0,0 @@
|
||||
.PHONY: validate-versions reset-versions
|
||||
|
||||
CONFIG=SUBMODULES.json
|
||||
|
||||
# usage $(call ValidateVersionTemplate (name,MAKEFILE VAR,repo name))
|
||||
# usage $(call ValidateVersionTemplate (mono,MONO,mono))
|
||||
|
||||
define ValidateVersionTemplate
|
||||
#$(eval REPOSITORY_$(2):=$(shell test -z $(3) && echo $(1) || echo "$(3)"))
|
||||
#$(eval DIRECTORY_$(2):=$(shell python versions.py get-dir $(1)))
|
||||
#$(eval DIRECTORY_$(2):=$(shell test -z $(DIRECTORY_$(2)) && echo $(1) || echo $(DIRECTORY_$(2))))
|
||||
#$(eval MODULE_$(2):=$(shell python versions.py get-url $(1)))
|
||||
#$(eval NEEDED_$(2)_VERSION:=$(shell python versions.py get-rev $(1)))
|
||||
#$(eval $(2)_BRANCH_AND_REMOTE:=$(shell python versions.py get-remote-branch $(1)))
|
||||
|
||||
#$(eval $(2)_VERSION:=$$$$(shell cd $($(2)_PATH) 2>/dev/null && git rev-parse HEAD ))
|
||||
|
||||
#$(eval NEEDED_$(2)_BRANCH:=$(word 2, $(subst /, ,$($(2)_BRANCH_AND_REMOTE))))
|
||||
#$(eval NEEDED_$(2)_REMOTE:=$(word 1, $(subst /, ,$($(2)_BRANCH_AND_REMOTE))))
|
||||
#$(eval $(2)_BRANCH:=$$$$(shell cd $($(2)_PATH) 2>/dev/null && git symbolic-ref --short HEAD 2>/dev/null))
|
||||
|
||||
validate-$(1)::
|
||||
@if test x$$(IGNORE_$(2)_VERSION) = "x"; then \
|
||||
if test ! -d $($(2)_PATH); then \
|
||||
if test x$$(RESET_VERSIONS) != "x"; then \
|
||||
$(MAKE) reset-$(1) || exit 1; \
|
||||
else \
|
||||
echo "Your $(1) checkout is missing, please run 'make reset-$(1)'"; \
|
||||
touch .validate-versions-failure; \
|
||||
fi; \
|
||||
else \
|
||||
if test "x$($(2)_VERSION)" != "x$(NEEDED_$(2)_VERSION)" ; then \
|
||||
if test x$$(RESET_VERSIONS) != "x"; then \
|
||||
$(MAKE) reset-$(1) || exit 1; \
|
||||
else \
|
||||
echo "Your $(1) version is out of date, please run 'make reset-$(1)' (found $($(2)_VERSION), expected $(NEEDED_$(2)_VERSION))"; \
|
||||
test -z "$(BUILD_REVISION)" || $(MAKE) test-$(1); \
|
||||
touch .validate-versions-failure; \
|
||||
fi; \
|
||||
elif test "x$($(2)_BRANCH)" != "x$(NEEDED_$(2)_BRANCH)" ; then \
|
||||
if test x$$(RESET_VERSIONS) != "x"; then \
|
||||
test -z "$(BUILD_REVISION)" || $(MAKE) test-$(1); \
|
||||
$(MAKE) reset-$(1) || exit 1; \
|
||||
else \
|
||||
echo "Your $(1) branch is out of date, please run 'make reset-$(1)' (found $($(2)_BRANCH), expected $(NEEDED_$(2)_BRANCH))"; \
|
||||
touch .validate-versions-failure; \
|
||||
fi; \
|
||||
fi; \
|
||||
fi; \
|
||||
fi
|
||||
|
||||
test-$(1)::
|
||||
@echo $(1)
|
||||
@echo " REPOSITORY_$(2)=$(REPOSITORY_$(2))"
|
||||
@echo " DIRECTORY_$(2)=$(DIRECTORY_$(2))"
|
||||
@echo " MODULE_$(2)=$(MODULE_$(2))"
|
||||
@echo " NEEDED_$(2)_VERSION=$(NEEDED_$(2)_VERSION)"
|
||||
@echo " $(2)_VERSION=$($(2)_VERSION)"
|
||||
@echo " $(2)_BRANCH_AND_REMOTE=$($(2)_BRANCH_AND_REMOTE)"
|
||||
@echo " NEEDED_$(2)_BRANCH=$(NEEDED_$(2)_BRANCH)"
|
||||
@echo " NEEDED_$(2)_REMOTE=$(NEEDED_$(2)_REMOTE)"
|
||||
@echo " $(2)_BRANCH=$($(2)_BRANCH)"
|
||||
@echo " $(2)_PATH=$($(2)_PATH) => $(abspath $($(2)_PATH))"
|
||||
|
||||
reset-$(1)::
|
||||
@if test -d $($(2)_PATH); then \
|
||||
if ! (cd $($(2)_PATH) && git show $(NEEDED_$(2)_VERSION) >/dev/null 2>&1 && git log -1 $(NEEDED_$(2)_REMOTE) >/dev/null 2>&1) ; then \
|
||||
echo "*** git fetch `basename $$($(2)_PATH)`" && (cd $($(2)_PATH) && git fetch); \
|
||||
fi; \
|
||||
else \
|
||||
echo "*** git clone $(MODULE_$(2)) --recursive $(DIRECTORY_$(2))" && (cd `dirname $($(2)_PATH)` && git clone $(MODULE_$(2)) --recursive $(DIRECTORY_$(2)) || exit 1 ); \
|
||||
fi
|
||||
@if test x$$(IGNORE_$(2)_VERSION) = "x"; then \
|
||||
echo "*** [$(1)] git checkout -f" $(NEEDED_$(2)_BRANCH) && (cd $($(2)_PATH) ; git checkout -f $(NEEDED_$(2)_BRANCH) || git checkout -f -b $($(2)_BRANCH_AND_REMOTE)); \
|
||||
echo "*** [$(1)] git reset --hard $(NEEDED_$(2)_VERSION)" && (cd $($(2)_PATH) && git reset --hard $(NEEDED_$(2)_VERSION)); \
|
||||
fi
|
||||
@echo "*** [$(1)] git submodule update --init --recursive" && (cd $($(2)_PATH) && git submodule update --init --recursive)
|
||||
|
||||
print-$(1)::
|
||||
@printf "*** %-16s %-45s %s (%s)\n" "$(DIRECTORY_$(2))" "$(MODULE_$(2))" "$(NEEDED_$(2)_VERSION)" "$(NEEDED_$(2)_BRANCH)"
|
||||
|
||||
.PHONY: validate-$(1) reset-$(1) print-$(1)
|
||||
|
||||
reset-versions:: reset-$(1)
|
||||
validate-versions:: Validate-$(1)
|
||||
print-versions:: print-$(1)
|
||||
|
||||
endef
|
||||
|
||||
$(eval $(call ValidateVersionTemplate,roslyn,ROSLYN))
|
||||
$(eval $(call ValidateVersionTemplate,coreclr,CORECLR))
|
||||
$(eval $(call ValidateVersionTemplate,ms-test-suite,MSTESTSUITE))
|
||||
|
||||
reset-versions::
|
||||
|
||||
validate-versions::
|
||||
@if test -e .validate-versions-failure; then \
|
||||
rm .validate-versions-failure; \
|
||||
echo One or more modules needs update; \
|
||||
exit 1; \
|
||||
else \
|
||||
echo All dependent modules up to date; \
|
||||
fi
|
||||
|
||||
reset:
|
||||
@$(MAKE) validate-versions RESET_VERSIONS=1
|
||||
|
||||
__bump-version-%:
|
||||
@if [ "$(REV)" = "" ]; then echo "Usage: make bump-version-$* REV=<ref>"; exit 1; fi
|
||||
python versions.py set-rev $* $(REV)
|
||||
@if [ "$(COMMIT)" = "1" ]; then echo "[acceptance-tests] Bump $* to pick up $(REV)." | git commit -F - $(CONFIG); fi
|
||||
|
||||
__bump-branch-%:
|
||||
@if [ "$(BRANCH)" = "" ]; then echo "Usage: make bump-branch-$* BRANCH=<branch> REMOTE_BRANCH=<remote branch>"; exit 1; fi
|
||||
@if [ "$(REMOTE_BRANCH)" == "" ]; then echo "Usage: make bump-branch-$* BRANCH=<branch> REMOTE_BRANCH=<remote branch>"; exit 1; fi
|
||||
python versions.py set-branch $* $(BRANCH)
|
||||
python versions.py set-remote-branch $* $(REMOTE_BRANCH)
|
||||
@if [ "$(COMMIT)" = "1" ]; then echo "[acceptance-tests] Bump $* to switch to $(BRANCH) $(REMOTE BRANCH)." | git commit -F - $(CONFIG); fi
|
||||
|
||||
__bump-current-version-%:
|
||||
REV=$(shell cd $(TOP)/../$* && git log -1 --pretty=format:%H); \
|
||||
python versions.py set-rev $* $$REV; \
|
||||
if [ "$(COMMIT)" = "1" ]; then echo "[acceptance-tests] Bump $* to pick up $$REV:" | git commit -F - $(CONFIG); fi
|
||||
|
||||
# Bump the given submodule to the revision given by the REV make variable
|
||||
# If COMMIT is 1, commit the change
|
||||
bump-roslyn: __bump-version-roslyn
|
||||
bump-coreclr: __bump-version-coreclr
|
||||
bump-ms-test-suite: __bump-version-ms-test-suite
|
||||
|
||||
# Bump the given submodule to the branch given by the BRANCH/REMOTE_BRANCH make variables
|
||||
# If COMMIT is 1, commit the change
|
||||
bump-branch-roslyn: __bump-branch-roslyn
|
||||
bump-branch-coreclr: __bump-branch-coreclr
|
||||
bump-branch-ms-test-suite: __bump-branch-ms-test-suite
|
||||
|
||||
# Bump the given submodule to its current GIT version
|
||||
# If COMMIT is 1, commit the change
|
||||
bump-current-roslyn: __bump-current-version-roslyn
|
||||
bump-current-coreclr: __bump-current-version-coreclr
|
||||
bump-current-ms-test-suite: __bump-current-version-ms-test-suite
|
||||
|
||||
commit-bump-roslyn:
|
||||
$(MAKE) bump-roslyn COMMIT=1
|
||||
|
||||
commit-bump-coreclr:
|
||||
$(MAKE) bump-coreclr COMMIT=1
|
||||
|
||||
commit-bump-ms-test-suite:
|
||||
$(MAKE) bump-ms-test-suite COMMIT=1
|
||||
|
||||
commit-bump-current-roslyn:
|
||||
$(MAKE) bump-current-roslyn COMMIT=1
|
||||
|
||||
commit-bump-current-coreclr:
|
||||
$(MAKE) bump-current-coreclr COMMIT=1
|
||||
|
||||
commit-bump-current-ms-test-suite:
|
||||
$(MAKE) bump-current-ms-test-suite COMMIT=1
|
||||
@@ -1,52 +0,0 @@
|
||||
#!/usr/bin/env python
|
||||
|
||||
import sys
|
||||
import json
|
||||
|
||||
def find_module(submodules, name):
|
||||
for item in submodules:
|
||||
if item["name"] == name:
|
||||
return item
|
||||
|
||||
print "Not found"
|
||||
sys.exit(1)
|
||||
|
||||
|
||||
if len(sys.argv) < 2:
|
||||
print "Usage: versions.py <command>"
|
||||
sys.exit(1)
|
||||
|
||||
CONFIG_FILE = "SUBMODULES.json"
|
||||
command = sys.argv[1]
|
||||
|
||||
submodules = json.load(open(CONFIG_FILE))
|
||||
|
||||
if command == "get-rev":
|
||||
mod = find_module(submodules, sys.argv[2])
|
||||
print mod["rev"]
|
||||
elif command == "get-url":
|
||||
mod = find_module(submodules, sys.argv[2])
|
||||
print mod["url"]
|
||||
elif command == "get-dir":
|
||||
mod = find_module(submodules, sys.argv[2])
|
||||
print mod["directory"]
|
||||
elif command == "get-remote-branch":
|
||||
mod = find_module(submodules, sys.argv[2])
|
||||
print mod["remote-branch"]
|
||||
elif command == "set-rev":
|
||||
mod = find_module(submodules, sys.argv[2])
|
||||
mod["rev"] = sys.argv[3]
|
||||
json.dump(submodules, open(CONFIG_FILE, "w"), indent = 2)
|
||||
elif command == "set-branch":
|
||||
mod = find_module(submodules, sys.argv[2])
|
||||
mod["branch"] = sys.argv[3]
|
||||
json.dump(submodules, open(CONFIG_FILE, "w"), indent = 2)
|
||||
elif command == "set-remote-branch":
|
||||
mod = find_module(submodules, sys.argv[2])
|
||||
mod["remote-branch"] = sys.argv[3]
|
||||
json.dump(submodules, open(CONFIG_FILE, "w"), indent = 2)
|
||||
elif command == "cat":
|
||||
print json.dumps(submodules, indent = 2)
|
||||
else:
|
||||
print "Unknown command "" + command + ""."
|
||||
sys.exit(1)
|
||||
+54
-28
@@ -4,41 +4,54 @@
|
||||
# For further details see http://www.appveyor.com
|
||||
#
|
||||
|
||||
# Use 'unstable' Appveyor build worker image as Appveyor have added Cygwin to this for us
|
||||
os: Unstable
|
||||
|
||||
#
|
||||
# Custom environment variables
|
||||
#
|
||||
environment:
|
||||
global:
|
||||
CYG_ROOT: C:\cygwin
|
||||
CYG_ROOT: C:/cygwin
|
||||
CYG_MIRROR: http://cygwin.mirror.constant.com
|
||||
CYG_CACHE: C:\cygwin\var\cache\setup
|
||||
CYG_BASH: C:\cygwin\bin\bash
|
||||
|
||||
#
|
||||
# Cache Cygwin files to speed up build
|
||||
#
|
||||
cache:
|
||||
- '%CYG_CACHE%'
|
||||
|
||||
#
|
||||
# Do a shallow clone of the repo to speed up build
|
||||
#
|
||||
clone_depth: 1
|
||||
|
||||
CYG_CACHE: C:/cygwin/var/cache/setup
|
||||
NSIS_ROOT: C:\nsis
|
||||
|
||||
#
|
||||
# Initialisation prior to pulling the Mono repository
|
||||
# Attempt to ensure we don't try to convert line endings to Win32 CRLF as this will cause build to fail
|
||||
#
|
||||
init:
|
||||
- git config --global core.autocrlf input
|
||||
- 'echo Building Mono for Windows'
|
||||
- 'echo System architecture: %PLATFORM%'
|
||||
- 'echo Repo build branch is: %APPVEYOR_REPO_BRANCH%'
|
||||
- 'echo Build folder is: %APPVEYOR_BUILD_FOLDER%'
|
||||
# Attempt to ensure we don't try to convert line endings to Win32 CRLF as this will cause build to fail
|
||||
- 'git config --global core.autocrlf input'
|
||||
|
||||
#
|
||||
# Install needed build dependencies
|
||||
#
|
||||
install:
|
||||
- ps: 'Start-FileDownload "http://cygwin.com/setup-x86.exe" -FileName "setup-x86.exe"'
|
||||
- 'setup-x86.exe --quiet-mode --no-shortcuts --only-site --root "%CYG_ROOT%" --site "%CYG_MIRROR%" --local-package-dir "%CYG_CACHE%" --packages autoconf,automake,bison,gcc-core,gcc-g++,mingw-runtime,mingw-binutils,mingw-gcc-core,mingw-gcc-g++,mingw-pthreads,mingw-w32api,libtool,make,python,gettext-devel,gettext,intltool,libiconv,pkg-config,git,curl,libxslt > NUL 2>&1'
|
||||
- '%CYG_BASH% -lc "cygcheck -dc cygwin"'
|
||||
# NOTE: Already installed on current Appveyor unstable image
|
||||
# - 'echo Retrieving Cygwin'
|
||||
# - 'appveyor DownloadFile http://cygwin.com/setup-x86.exe -FileName %CYGROOT%/setup-x86.exe'
|
||||
- 'echo Setting up Cygwin dependencies'
|
||||
- '%CYG_ROOT%\setup-x86.exe -qnNdO -R "%CYG_ROOT%" -s "%CYG_MIRROR%" -l "%CYG_CACHE%" -P autoconf -P automake -P bison -P gcc-core -P gcc-g++ -P mingw-runtime -P mingw-binutils -P mingw-gcc-core -P mingw-gcc-g++ -P mingw-pthreads -P mingw-w32api -P libtool -P make -P python -P gettext-devel -P gettext -P intltool -P libiconv -P pkg-config -P git -P wget -P curl > NUL'
|
||||
- 'echo Check Cygwin setup'
|
||||
- '%CYG_ROOT%/bin/bash -lc "cygcheck -dc cygwin"'
|
||||
- 'echo Done setting up Cygwin'
|
||||
- 'echo Retrieving NSIS'
|
||||
- 'appveyor DownloadFile "http://sunet.dl.sourceforge.net/project/nsis/NSIS 2/2.46/nsis-2.46-setup.exe" -FileName nsissetup.exe'
|
||||
- 'echo Setting up NSIS'
|
||||
- 'nsissetup.exe /S /D=%NSIS_ROOT%'
|
||||
- 'echo Done setting up NSIS'
|
||||
|
||||
#
|
||||
# NOTE: msbuild doesn't work at present so use Cygwin to build
|
||||
#
|
||||
#build:
|
||||
# project: C:\projects\mono\msvc\mono.sln
|
||||
# verbosity: detailed
|
||||
|
||||
# Cygwin build script
|
||||
#
|
||||
@@ -46,16 +59,29 @@ install:
|
||||
#
|
||||
# The stdin/stdout file descriptor appears not to be valid for the Appveyor
|
||||
# build which causes failures as certain functions attempt to redirect
|
||||
# default file handles. Ensure a dummy file descriptor is opened with 'exec'.
|
||||
# default file handles. Ensure a dummy file descriptor is opened with exec.
|
||||
#
|
||||
build_script:
|
||||
- 'echo Building...'
|
||||
- '%CYG_BASH% -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; ./autogen.sh --prefix=/usr/local --host=i686-pc-mingw32"'
|
||||
- '%CYG_BASH% -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make get-monolite-latest"'
|
||||
- '%CYG_BASH% -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make -j2"'
|
||||
- 'echo Installing...'
|
||||
- 'mkdir %APPVEYOR_BUILD_FOLDER%\install'
|
||||
- '%CYG_BASH% -lc "export CYGWIN=winsymlinks:native; mount \"$APPVEYOR_BUILD_FOLDER\install\" /usr/local; cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make install; umount /usr/local"'
|
||||
- cmd: 'echo Cygwin root is: %CYG_ROOT%'
|
||||
- cmd: 'echo Build folder is: %APPVEYOR_BUILD_FOLDER%'
|
||||
- cmd: 'echo Repo build branch is: %APPVEYOR_REPO_BRANCH%'
|
||||
- cmd: 'echo Repo build commit is: %APPVEYOR_REPO_COMMIT%'
|
||||
- cmd: 'echo Autogen running...'
|
||||
- cmd: '%CYG_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; NOCONFIGURE=1 ./autogen.sh --prefix=/usr/local --with-preview=yes"'
|
||||
- cmd: 'echo Configure running...'
|
||||
- cmd: '%CYG_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; ./configure --host=i686-pc-mingw32"'
|
||||
- cmd: 'echo Pulling monolite latest...'
|
||||
- cmd: '%CYG_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make get-monolite-latest"'
|
||||
- cmd: 'echo Make running...'
|
||||
- cmd: '%CYG_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make"'
|
||||
- cmd: 'echo Installing...'
|
||||
- cmd: 'mkdir %APPVEYOR_BUILD_FOLDER%\install'
|
||||
- cmd: '%CYG_ROOT%/bin/bash --login -lc "export CYGWIN=winsymlinks:native; mount \"$APPVEYOR_BUILD_FOLDER\install\" /usr/local; cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make install; umount /usr/local"'
|
||||
# - cmd: 'echo Building package...'
|
||||
# - cmd: 'cd %APPVEYOR_BUILD_FOLDER%'
|
||||
# - cmd: '%NSIS_ROOT%\makensis /DMILESTONE=%APPVEYOR_REPO_BRANCH% /DSOURCE_INSTALL_DIR=%APPVEYOR_BUILD_FOLDER\install\*.* /DBUILDNUM=%APPVEYOR_BUILD_VERSION% monowiz.win32.nsi'
|
||||
# - cmd: 'Building distribution...'
|
||||
# - cmd: '%CYG_ROOT%/bin/bash -lc "export CYGWIN=winsymlinks:native; cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make dist"'
|
||||
|
||||
#
|
||||
# Disable tests for now
|
||||
|
||||
+8
-8
@@ -30,18 +30,18 @@ fi
|
||||
DIE=1
|
||||
}
|
||||
|
||||
if [ -z "$LIBTOOLIZE" ]; then
|
||||
LIBTOOLIZE=`which glibtoolize 2>/dev/null`
|
||||
if [ ! -x "$LIBTOOLIZE" ]; then
|
||||
LIBTOOLIZE=`which libtoolize`
|
||||
if [ -z "$LIBTOOL" ]; then
|
||||
LIBTOOL=`which glibtool 2>/dev/null`
|
||||
if [ ! -x "$LIBTOOL" ]; then
|
||||
LIBTOOL=`which libtool`
|
||||
fi
|
||||
fi
|
||||
|
||||
(grep "^AM_PROG_LIBTOOL" $srcdir/configure.ac >/dev/null) && {
|
||||
($LIBTOOLIZE --version) < /dev/null > /dev/null 2>&1 || {
|
||||
($LIBTOOL --version) < /dev/null > /dev/null 2>&1 || {
|
||||
echo
|
||||
echo "**Error**: You must have \`libtoolize' installed to compile Mono."
|
||||
echo "Get ftp://ftp.gnu.org/gnu/libtool/libtool-1.2.tar.gz"
|
||||
echo "**Error**: You must have \`libtool' installed to compile Mono."
|
||||
echo "Get ftp://ftp.gnu.org/pub/gnu/libtool-1.2d.tar.gz"
|
||||
echo "(or a newer version if it is available)"
|
||||
DIE=1
|
||||
}
|
||||
@@ -98,7 +98,7 @@ esac
|
||||
if grep "^AM_PROG_LIBTOOL" configure.ac >/dev/null; then
|
||||
if test -z "$NO_LIBTOOLIZE" ; then
|
||||
echo "Running libtoolize..."
|
||||
$LIBTOOLIZE --force --copy
|
||||
${LIBTOOL}ize --force --copy
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
Executable
+227
@@ -0,0 +1,227 @@
|
||||
#!/bin/bash -e
|
||||
CURDIR="`pwd`"
|
||||
MINGW=i386-mingw32msvc
|
||||
CROSS_DIR=/opt/cross/$MINGW
|
||||
EXTRA_CROSS_DIR=
|
||||
INSTALL_DESTDIR="$CURDIR/mono-win32"
|
||||
PROFILES="default net_2_0 net_3_5 net_4_0 net_4_5 moonlight"
|
||||
TEMPORARY_PKG_CONFIG_DIR=/tmp/$RANDOM-pkg-config-$RANDOM
|
||||
ORIGINAL_PATH="$PATH"
|
||||
|
||||
export CPPFLAGS_FOR_EGLIB CFLAGS_FOR_EGLIB CPPFLAGS_FOR_LIBGC CFLAGS_FOR_LIBGC
|
||||
|
||||
function cleanup ()
|
||||
{
|
||||
if [ -d "$TEMPORARY_PKG_CONFIG_DIR" ]; then
|
||||
rm -rf "$TEMPORARY_PKG_CONFIG_DIR"
|
||||
fi
|
||||
}
|
||||
|
||||
function check_pkg_config_dir ()
|
||||
{
|
||||
local DIR="$1"
|
||||
local DIR_PREFIX="$2"
|
||||
|
||||
if [ ! -d "$DIR" ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
install -d -m 755 "$TEMPORARY_PKG_CONFIG_DIR"
|
||||
for pc in "$DIR"/*.pc; do
|
||||
if [ -f $pc ]; then
|
||||
pcname="`basename $pc`"
|
||||
sed -e "s;^prefix=.*;prefix=$DIR_PREFIX;g" < $pc > "$TEMPORARY_PKG_CONFIG_DIR"/$pcname
|
||||
fi;
|
||||
done
|
||||
|
||||
if [ -z "$CROSS_PKG_CONFIG_DIR" ]; then
|
||||
CROSS_PKG_CONFIG_DIR="$TEMPORARY_PKG_CONFIG_DIR"
|
||||
fi
|
||||
}
|
||||
|
||||
function show_build_info ()
|
||||
{
|
||||
cat <<EOF
|
||||
Installation prefix: $MONO_PREFIX
|
||||
CPPFLAGS: ${CPPFLAGS:=not set}
|
||||
LDFLAGS: ${LDFLAGS:=not set}
|
||||
MONO_PATH: ${MONO_PATH:=not set}
|
||||
EOF
|
||||
}
|
||||
|
||||
function setup ()
|
||||
{
|
||||
local pcname
|
||||
|
||||
CROSS_BIN_DIR="$CROSS_DIR/bin"
|
||||
CROSS_DLL_DIR="$CROSS_DIR/bin"
|
||||
PATH=$CROSS_BIN_DIR:$PATH
|
||||
|
||||
MONO_VERSION=`grep AC_INIT configure.ac | cut -d ',' -f 2|tr -d '\[ \]'`
|
||||
|
||||
if [ -d ./.git ]; then
|
||||
MONO_GIT_COMMIT="`git log -1 --format=format:%t`"
|
||||
MONO_GIT_BRANCH="`git branch|grep '\*'|cut -d ' ' -f 2|tr -d '\)'|tr -d '\('`"
|
||||
MONO_RELEASE="$MONO_VERSION-$MONO_GIT_BRANCH-$MONO_GIT_COMMIT"
|
||||
else
|
||||
MONO_RELEASE="$MONO_VERSION"
|
||||
fi
|
||||
|
||||
MONO_PREFIX="$MONO_PREFIX/mono-$MONO_RELEASE"
|
||||
|
||||
NOCONFIGURE=yes
|
||||
export NOCONFIGURE
|
||||
|
||||
check_pkg_config_dir "$CROSS_DIR/lib/pkgconfig" "$CROSS_DIR"
|
||||
|
||||
if [ -n "$EXTRA_CROSS_DIR" -a -d "$EXTRA_CROSS_DIR" ]; then
|
||||
if [ -d "$EXTRA_CROSS_DIR/bin" ]; then
|
||||
PATH="$EXTRA_CROSS_DIR/bin":$PATH
|
||||
fi
|
||||
|
||||
check_pkg_config_dir "$EXTRA_CROSS_DIR/lib/pkgconfig" "$EXTRA_CROSS_DIR"
|
||||
|
||||
if [ -d "$EXTRA_CROSS_DIR/include" ]; then
|
||||
if [ -z "$CPPFLAGS" ]; then
|
||||
CPPFLAGS="-I \"$EXTRA_CROSS_DIR/include\""
|
||||
else
|
||||
CPPFLAGS="-I \"$EXTRA_CROSS_DIR/include\" $CFLAGS"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -d "$EXTRA_CROSS_DIR/lib" ]; then
|
||||
if [ -z "$LDFLAGS" ]; then
|
||||
LDFLAGS="-I \"$EXTRA_CROSS_DIR/lib\""
|
||||
else
|
||||
LDFLAGS="-I \"$EXTRA_CROSS_DIR/lib\" $LDFLAGS"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ -d "$EXTRA_CROSS_DIR/share/aclocal" ]; then
|
||||
if [ -z "$MONO_PATH" ]; then
|
||||
MONO_PATH="\"$EXTRA_CROSS_DIR\""
|
||||
else
|
||||
MONO_PATH="\"$EXTRA_CROSS_DIR\":$MONO_PATH"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
export PATH MONO_PATH CPPFLAGS
|
||||
show_build_info
|
||||
}
|
||||
|
||||
function build ()
|
||||
{
|
||||
if [ -f ./Makefile ]; then
|
||||
make distclean
|
||||
fi
|
||||
|
||||
if [ -d ./autom4te.cache ]; then
|
||||
rm -rf ./autom4te.cache
|
||||
fi
|
||||
|
||||
if [ -f ./config.status ]; then
|
||||
for f in `find -name config.status -type f`; do
|
||||
rm $f
|
||||
done
|
||||
fi
|
||||
|
||||
./autogen.sh
|
||||
|
||||
BUILD="`./config.guess`"
|
||||
|
||||
if [ ! -d "$CURDIR/build-cross-windows" ]; then
|
||||
mkdir "$CURDIR/build-cross-windows"
|
||||
fi
|
||||
|
||||
cd "$CURDIR/build-cross-windows"
|
||||
rm -rf *
|
||||
../configure --prefix=$MONO_PREFIX --with-crosspkgdir=$CROSS_PKG_CONFIG_DIR --build=$BUILD --target=$MINGW --host=$MINGW --enable-parallel-mark --program-transform-name="" --with-tls=none --disable-mcs-build --disable-embed-check --enable-win32-dllmain=yes --with-libgc-threads=win32 --with-profile4=yes
|
||||
make
|
||||
cd "$CURDIR"
|
||||
|
||||
if [ ! -d "$CURDIR/build-cross-windows-mcs" ]; then
|
||||
mkdir "$CURDIR/build-cross-windows-mcs"
|
||||
fi
|
||||
|
||||
rm -rf autom4te.cache
|
||||
unset PATH
|
||||
PATH="$ORIGINAL_PATH"
|
||||
export PATH
|
||||
cd "$CURDIR/build-cross-windows-mcs"
|
||||
rm -rf *
|
||||
../configure --prefix=$MONO_PREFIX --enable-parallel-mark
|
||||
make
|
||||
}
|
||||
|
||||
function doinstall ()
|
||||
{
|
||||
if [ -d "$INSTALL_DIR" ]; then
|
||||
rm -rf "$INSTALL_DIR"
|
||||
fi
|
||||
cd "$CURDIR/build-cross-windows"
|
||||
make DESTDIR="$INSTALL_DESTDIR" USE_BATCH_FILES=yes install
|
||||
|
||||
if test -d $CURDIR/mcs; then
|
||||
mcsdir=$CURDIR/mcs
|
||||
else
|
||||
mcsdir=$CURDIR/../mcs
|
||||
fi
|
||||
|
||||
cd "$mcsdir/mcs"
|
||||
for p in $PROFILES; do
|
||||
make DESTDIR="$INSTALL_DESTDIR" PROFILE=$p install || echo "mcs profile $p installation failed"
|
||||
done
|
||||
|
||||
cd "$mcsdir/class"
|
||||
for p in $PROFILES; do
|
||||
make DESTDIR="$INSTALL_DESTDIR" PROFILE=$p install || echo "class library profile $p installation failed"
|
||||
done
|
||||
|
||||
cd "$mcsdir/tools"
|
||||
for p in $PROFILES; do
|
||||
make DESTDIR="$INSTALL_DESTDIR" PROFILE=$p install || echo "tools profile $p installation failed"
|
||||
done
|
||||
|
||||
cd "$CURDIR/mono-win32"
|
||||
rm -f "$CURDIR/mono-win32-$MONO_RELEASE".zip
|
||||
zip -9r "$CURDIR/mono-win32-$MONO_RELEASE".zip .
|
||||
|
||||
}
|
||||
|
||||
function usage ()
|
||||
{
|
||||
cat <<EOF
|
||||
Usage: build-mingw32.sh [OPTIONS]
|
||||
|
||||
where OPTIONS are:
|
||||
|
||||
-d DIR Sets the location of directory where MINGW is installed [$CROSS_DIR]
|
||||
-e DIR Sets the location of directory where additional cross develoment packages are installed [${EXTRA_CROSS_DIR:=none}]
|
||||
-m MINGW Sets the MINGW target name to be passed to configure [$MINGW]
|
||||
-p PREFIX Prefix at which Mono is to be installed. Build will append the 'mono-X.Y' string to that path
|
||||
EOF
|
||||
|
||||
exit 1
|
||||
}
|
||||
|
||||
trap cleanup 0
|
||||
|
||||
pushd . > /dev/null
|
||||
|
||||
while getopts "d:m:e:p:" opt; do
|
||||
case "$opt" in
|
||||
d) CROSS_DIR="$OPTARG" ;;
|
||||
m) MINGW="$OPTARG" ;;
|
||||
e) EXTRA_CROSS_DIR="$OPTARG" ;;
|
||||
p) MONO_PREFIX="$OPTARG" ;;
|
||||
*) usage ;;
|
||||
esac
|
||||
done
|
||||
|
||||
setup
|
||||
build
|
||||
doinstall
|
||||
show_build_info
|
||||
|
||||
popd > /dev/null
|
||||
@@ -1,50 +0,0 @@
|
||||
# Contributor Code of Conduct
|
||||
|
||||
As contributors and maintainers of this project, and in the interest of
|
||||
fostering an open and welcoming community, we pledge to respect all people who
|
||||
contribute through reporting issues, posting feature requests, updating
|
||||
documentation, submitting pull requests or patches, and other activities.
|
||||
|
||||
We are committed to making participation in this project a harassment-free
|
||||
experience for everyone, regardless of level of experience, gender, gender
|
||||
identity and expression, sexual orientation, disability, personal appearance,
|
||||
body size, race, ethnicity, age, religion, or nationality.
|
||||
|
||||
Examples of unacceptable behavior by participants include:
|
||||
|
||||
* The use of sexualized language or imagery
|
||||
* Personal attacks
|
||||
* Trolling or insulting/derogatory comments
|
||||
* Public or private harassment
|
||||
* Publishing other's private information, such as physical or electronic
|
||||
addresses, without explicit permission
|
||||
* Other unethical or unprofessional conduct
|
||||
|
||||
Project maintainers have the right and responsibility to remove, edit, or
|
||||
reject comments, commits, code, wiki edits, issues, and other contributions
|
||||
that are not aligned to this Code of Conduct, or to ban temporarily or
|
||||
permanently any contributor for other behaviors that they deem inappropriate,
|
||||
threatening, offensive, or harmful.
|
||||
|
||||
By adopting this Code of Conduct, project maintainers commit themselves to
|
||||
fairly and consistently applying these principles to every aspect of managing
|
||||
this project. Project maintainers who do not follow or enforce the Code of
|
||||
Conduct may be permanently removed from the project team.
|
||||
|
||||
This Code of Conduct applies both within project spaces and in public spaces
|
||||
when an individual is representing the project or its community.
|
||||
|
||||
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
||||
reported by contacting a project maintainer at miguel@xamarin.com. All
|
||||
complaints will be reviewed and investigated and will result in a response that
|
||||
is deemed necessary and appropriate to the circumstances. Maintainers are
|
||||
obligated to maintain confidentiality with regard to the reporter of an
|
||||
incident.
|
||||
|
||||
|
||||
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
|
||||
version 1.3.0, available at
|
||||
[http://contributor-covenant.org/version/1/3/0/][version]
|
||||
|
||||
[homepage]: http://contributor-covenant.org
|
||||
[version]: http://contributor-covenant.org/version/1/3/0/
|
||||
+277
-305
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,6 @@
|
||||
2008-03-23 Dean Brettle <[email protected]>
|
||||
|
||||
* Compat.browser: added. Provides browser definitions with
|
||||
compatible IDs.
|
||||
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
2010-05-17 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-2.pc.in (Libs): Remove glib dependencies.
|
||||
|
||||
2010-05-07 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-2.pc (Requires): Remove glib dependencies.
|
||||
|
||||
2010-04-02 Jb Evain <[email protected]>
|
||||
|
||||
* dotnet35.pc.in: add System.Data.Services.dll.
|
||||
|
||||
2010-03-08 Rodrigo Kumpera <[email protected]>
|
||||
|
||||
* mono.supp: Add hazard pointers supressions.
|
||||
+2
-3
@@ -5,7 +5,7 @@ monolldbdir = $(libdir)/mono/lldb
|
||||
|
||||
EXTRA_DIST = \
|
||||
config.in \
|
||||
browscap.ini mono.supp mono.d README \
|
||||
browscap.ini mono.supp mono.d README ChangeLog \
|
||||
mono.pc.in mono-2.pc.in monosgen-2.pc.in mint.pc.in dotnet.pc.in dotnet35.pc.in wcf.pc.in monodoc.pc.in \
|
||||
mono-nunit.pc.in mono-cairo.pc.in mono-options.pc.in cecil.pc.in \
|
||||
mono-lineeditor.pc.in system.web.extensions_1.0.pc.in system.web.extensions.design_1.0.pc.in\
|
||||
@@ -14,8 +14,7 @@ EXTRA_DIST = \
|
||||
net_1_1/machine.config \
|
||||
gdb/mono-gdb.py \
|
||||
gdb/gdb-python.diff \
|
||||
lldb/mono.py \
|
||||
lldb/monobt.py
|
||||
lldb/mono.py
|
||||
|
||||
pkgconfigdir = $(libdir)/pkgconfig
|
||||
|
||||
|
||||
+1
-1
@@ -10,7 +10,7 @@
|
||||
<dllmap dll="i:odbc32.dll" target="libiodbc.dylib" os="osx"/>
|
||||
<dllmap dll="oci" target="libclntsh@libsuffix@" os="!windows"/>
|
||||
<dllmap dll="db2cli" target="libdb2_36@libsuffix@" os="!windows"/>
|
||||
<dllmap dll="MonoPosixHelper" target="$mono_libdir/libMonoPosixHelper@libsuffix@" os="!windows" />
|
||||
<dllmap dll="MonoPosixHelper" target="@prefix@/@reloc_libdir@/libMonoPosixHelper@libsuffix@" os="!windows" />
|
||||
<dllmap dll="i:msvcrt" target="@LIBC@" os="!windows"/>
|
||||
<dllmap dll="i:msvcrt.dll" target="@LIBC@" os="!windows"/>
|
||||
<dllmap dll="sqlite" target="@SQLITE@" os="!windows"/>
|
||||
|
||||
@@ -0,0 +1,66 @@
|
||||
2009-10-09 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (MonoSupport.run_hook): Set MONO_XDEBUG to 'gdb' to activate
|
||||
the GDB support mode in the runtime.
|
||||
|
||||
2009-04-14 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (MonoClassPrinter.to_string): Add a MonoClass* pretty
|
||||
printer.
|
||||
|
||||
2009-04-12 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (MonoMethodPrinter.to_string): Add a MonoMethod* pretty
|
||||
printer.
|
||||
|
||||
2009-04-10 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Update to the latest archer api.
|
||||
|
||||
2009-04-07 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (ObjectPrinter.__init__): Update to latest archer api.
|
||||
|
||||
2009-04-06 Zoltan Varga <[email protected]>
|
||||
|
||||
* test-xdb.py: New file, tester script for xdb.
|
||||
|
||||
* mono-gdb.py (stringify_class_name): Handle classes without a namespace
|
||||
correctly.
|
||||
|
||||
* mono-gdb.py: Update after the changes to dwarfwriter.c.
|
||||
|
||||
2009-04-05 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Handle superclasses in the pretty printer.
|
||||
|
||||
2009-03-27 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (StringPrinter.to_string): Fix support for non-ascii characters.
|
||||
|
||||
2009-03-20 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Update for the latest python API on the archer branch.
|
||||
|
||||
2009-02-03 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Remove the --64 argument to as, it is not needed.
|
||||
|
||||
* mono-gdb.py (stringify_class_name): Helper function to print base types
|
||||
using their short name. Also add a prototype implementation of registering
|
||||
the hooks from python code instead of needing the mono-gdbinit file.
|
||||
|
||||
* gdb-python.diff: Changes against the gdb archer branch at
|
||||
http://sourceware.org/gdb/wiki/PythonGdb to fix some problems/add functionality.
|
||||
|
||||
2009-02-03 Geoff Norton <[email protected]>
|
||||
|
||||
* mono-gdbinit: Hook into backtrace as hook-stop seems to crash gdb
|
||||
* mono-gdb.py: Find the gdbinit name from the executable name instead of
|
||||
hardcoding mono
|
||||
|
||||
2009-01-29 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py mono-gdbinit: Support files to help debugging mono/mono apps
|
||||
using a python enabled gdb.
|
||||
|
||||
+14
-14
@@ -53,7 +53,7 @@ def stringify_class_name(ns, name):
|
||||
if ns == "":
|
||||
return name
|
||||
else:
|
||||
return "{}.{}".format (ns, name)
|
||||
return "%s.%s".format (ns, name)
|
||||
|
||||
class ArrayPrinter:
|
||||
"Print a C# array"
|
||||
@@ -66,7 +66,7 @@ class ArrayPrinter:
|
||||
def to_string(self):
|
||||
obj = self.val.cast (gdb.lookup_type ("MonoArray").pointer ()).dereference ()
|
||||
length = obj ['max_length']
|
||||
return "{} [{}]".format (stringify_class_name (self.class_ns, self.class_name [0:len (self.class_name) - 2]), int (length))
|
||||
return "%s [%d]".format (stringify_class_name (self.class_ns, self.class_name [0:len (self.class_name) - 2]), int (length))
|
||||
|
||||
class ObjectPrinter:
|
||||
"Print a C# object"
|
||||
@@ -96,7 +96,7 @@ class ObjectPrinter:
|
||||
return (field.name, self.obj [field.name])
|
||||
except:
|
||||
# Superclass
|
||||
return (field.name, self.obj.cast (gdb.lookup_type ("{}".format (field.name))))
|
||||
return (field.name, self.obj.cast (gdb.lookup_type ("%s".format (field.name))))
|
||||
|
||||
def children(self):
|
||||
# FIXME: It would be easier if gdb.Value would support iteration itself
|
||||
@@ -109,7 +109,7 @@ class ObjectPrinter:
|
||||
class_name = obj ['vtable'].dereference ()['klass'].dereference ()['name'].string ()
|
||||
if class_name [-2:len(class_name)] == "[]":
|
||||
return {}.__iter__ ()
|
||||
gdb_type = gdb.lookup_type ("struct {}_{}".format (class_ns.replace (".", "_"), class_name))
|
||||
gdb_type = gdb.lookup_type ("struct %s_%s".format (class_ns.replace (".", "_"), class_name))
|
||||
return self._iterator(obj.cast (gdb_type))
|
||||
except:
|
||||
print (sys.exc_info ()[0])
|
||||
@@ -129,12 +129,12 @@ class ObjectPrinter:
|
||||
return ArrayPrinter (self.val,class_ns,class_name).to_string ()
|
||||
if class_ns != "":
|
||||
try:
|
||||
gdb_type = gdb.lookup_type ("struct {}.{}".format (class_ns, class_name))
|
||||
gdb_type = gdb.lookup_type ("struct %s.%s".format (class_ns, class_name))
|
||||
except:
|
||||
# Maybe there is no debug info for that type
|
||||
return "{}.{}".format (class_ns, class_name)
|
||||
return "%s.%s".format (class_ns, class_name)
|
||||
#return obj.cast (gdb_type)
|
||||
return "{}.{}".format (class_ns, class_name)
|
||||
return "%s.%s".format (class_ns, class_name)
|
||||
return class_name
|
||||
except:
|
||||
print (sys.exc_info ()[0])
|
||||
@@ -154,9 +154,9 @@ class MonoMethodPrinter:
|
||||
val = self.val.dereference ()
|
||||
klass = val ["klass"].dereference ()
|
||||
class_name = stringify_class_name (klass ["name_space"].string (), klass ["name"].string ())
|
||||
return "\"{}:{} ()\"".format (class_name, val ["name"].string ())
|
||||
return "\"%s:%s ()\"".format (class_name, val ["name"].string ())
|
||||
# This returns more info but requires calling into the inferior
|
||||
#return "\"{}\"".format (gdb.parse_and_eval ("mono_method_full_name ({}, 1)".format (str (int (self.val.cast (gdb.lookup_type ("guint64")))))).string ())
|
||||
#return "\"%s\"".format (gdb.parse_and_eval ("mono_method_full_name (%s, 1)".format (str (int (self.val.cast (gdb.lookup_type ("guint64")))))).string ())
|
||||
|
||||
class MonoClassPrinter:
|
||||
"Print a MonoClass structure"
|
||||
@@ -169,9 +169,9 @@ class MonoClassPrinter:
|
||||
return "0x0"
|
||||
klass = self.val.dereference ()
|
||||
class_name = stringify_class_name (klass ["name_space"].string (), klass ["name"].string ())
|
||||
return "\"{}\"".format (class_name)
|
||||
return "\"%s\"".format (class_name)
|
||||
# This returns more info but requires calling into the inferior
|
||||
#return "\"{}\"".format (gdb.parse_and_eval ("mono_type_full_name (&((MonoClass*){})->byval_arg)".format (str (int ((self.val).cast (gdb.lookup_type ("guint64")))))))
|
||||
#return "\"%s\"".format (gdb.parse_and_eval ("mono_type_full_name (&((MonoClass*)%s)->byval_arg)".format (str (int ((self.val).cast (gdb.lookup_type ("guint64")))))))
|
||||
|
||||
def lookup_pretty_printer(val):
|
||||
t = str (val.type)
|
||||
@@ -217,9 +217,9 @@ class MonoSupport(object):
|
||||
new_size = os.stat ("xdb.s").st_size
|
||||
if new_size > self.s_size:
|
||||
sofile = "xdb.so"
|
||||
gdb.execute ("shell as -o xdb.o xdb.s && ld -shared -o {} xdb.o".format (sofile))
|
||||
gdb.execute ("shell as -o xdb.o xdb.s && ld -shared -o %s xdb.o".format (sofile))
|
||||
# FIXME: This prints messages which couldn't be turned off
|
||||
gdb.execute ("add-symbol-file {} 0".format (sofile))
|
||||
gdb.execute ("add-symbol-file %s 0".format (sofile))
|
||||
self.s_size = new_size
|
||||
|
||||
class RunHook (gdb.Command):
|
||||
@@ -245,4 +245,4 @@ exec_file = gdb.current_objfile ().filename
|
||||
if os.stat (exec_file).st_size != os.lstat (exec_file).st_size:
|
||||
exec_file = os.readlink (exec_file)
|
||||
exec_dir = os.path.dirname (exec_file)
|
||||
gdb.execute ("source {}/{}-gdbinit".format (exec_dir, os.path.basename (exec_file)))
|
||||
gdb.execute ("source %s/%s-gdbinit".format (exec_dir, os.path.basename (exec_file)))
|
||||
@@ -0,0 +1,80 @@
|
||||
2010-06-28 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Add pretty printers for more runtime data structures.
|
||||
|
||||
2009-10-13 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Add an 'xdb' command to flush the debugging info.
|
||||
|
||||
2009-10-12 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Update this to gdb 7.0.
|
||||
|
||||
* mono-gdbinit: Removed, no longer needed.
|
||||
|
||||
2009-10-09 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (MonoSupport.run_hook): Set MONO_XDEBUG to 'gdb' to activate
|
||||
the GDB support mode in the runtime.
|
||||
|
||||
2009-04-14 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (MonoClassPrinter.to_string): Add a MonoClass* pretty
|
||||
printer.
|
||||
|
||||
2009-04-12 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (MonoMethodPrinter.to_string): Add a MonoMethod* pretty
|
||||
printer.
|
||||
|
||||
2009-04-10 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Update to the latest archer api.
|
||||
|
||||
2009-04-07 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (ObjectPrinter.__init__): Update to latest archer api.
|
||||
|
||||
2009-04-06 Zoltan Varga <[email protected]>
|
||||
|
||||
* test-xdb.py: New file, tester script for xdb.
|
||||
|
||||
* mono-gdb.py (stringify_class_name): Handle classes without a namespace
|
||||
correctly.
|
||||
|
||||
* mono-gdb.py: Update after the changes to dwarfwriter.c.
|
||||
|
||||
2009-04-05 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Handle superclasses in the pretty printer.
|
||||
|
||||
2009-03-27 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py (StringPrinter.to_string): Fix support for non-ascii characters.
|
||||
|
||||
2009-03-20 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Update for the latest python API on the archer branch.
|
||||
|
||||
2009-02-03 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py: Remove the --64 argument to as, it is not needed.
|
||||
|
||||
* mono-gdb.py (stringify_class_name): Helper function to print base types
|
||||
using their short name. Also add a prototype implementation of registering
|
||||
the hooks from python code instead of needing the mono-gdbinit file.
|
||||
|
||||
* gdb-python.diff: Changes against the gdb archer branch at
|
||||
http://sourceware.org/gdb/wiki/PythonGdb to fix some problems/add functionality.
|
||||
|
||||
2009-02-03 Geoff Norton <[email protected]>
|
||||
|
||||
* mono-gdbinit: Hook into backtrace as hook-stop seems to crash gdb
|
||||
* mono-gdb.py: Find the gdbinit name from the executable name instead of
|
||||
hardcoding mono
|
||||
|
||||
2009-01-29 Zoltan Varga <[email protected]>
|
||||
|
||||
* mono-gdb.py mono-gdbinit: Support files to help debugging mono/mono apps
|
||||
using a python enabled gdb.
|
||||
|
||||
+18
-18
@@ -31,7 +31,7 @@ class StringPrinter:
|
||||
while i < len:
|
||||
val = (chars.cast(gdb.lookup_type ("gint64")) + (i * 2)).cast(gdb.lookup_type ("gunichar2").pointer ()).dereference ()
|
||||
if val >= 256:
|
||||
c = unichr (val)
|
||||
c = "\u%X".format (val)
|
||||
else:
|
||||
c = chr (val)
|
||||
res.append (c)
|
||||
@@ -48,7 +48,7 @@ def stringify_class_name(ns, name):
|
||||
if ns == "":
|
||||
return name
|
||||
else:
|
||||
return "{}.{}".format (ns, name)
|
||||
return "%s.%s".format (ns, name)
|
||||
|
||||
class ArrayPrinter:
|
||||
"Print a C# array"
|
||||
@@ -61,7 +61,7 @@ class ArrayPrinter:
|
||||
def to_string(self):
|
||||
obj = self.val.cast (gdb.lookup_type ("MonoArray").pointer ()).dereference ()
|
||||
length = obj ['max_length']
|
||||
return "{} [{}]".format (stringify_class_name (self.class_ns, self.class_name [0:len(self.class_name) - 2]), int(length))
|
||||
return "%s [%d]".format (stringify_class_name (self.class_ns, self.class_name [0:len(self.class_name) - 2]), int(length))
|
||||
|
||||
class ObjectPrinter:
|
||||
"Print a C# object"
|
||||
@@ -91,7 +91,7 @@ class ObjectPrinter:
|
||||
return (field.name, self.obj [field.name])
|
||||
except:
|
||||
# Superclass
|
||||
return (field.name, self.obj.cast (gdb.lookup_type ("{}".format (field.name))))
|
||||
return (field.name, self.obj.cast (gdb.lookup_type ("%s".format (field.name))))
|
||||
|
||||
def children(self):
|
||||
# FIXME: It would be easier if gdb.Value would support iteration itself
|
||||
@@ -105,7 +105,7 @@ class ObjectPrinter:
|
||||
if class_name [-2:len(class_name)] == "[]":
|
||||
return {}.__iter__ ()
|
||||
try:
|
||||
gdb_type = gdb.lookup_type ("struct {}_{}".format (class_ns.replace (".", "_"), class_name))
|
||||
gdb_type = gdb.lookup_type ("struct %s_%s".format (class_ns.replace (".", "_"), class_name))
|
||||
return self._iterator(obj.cast (gdb_type))
|
||||
except:
|
||||
return {}.__iter__ ()
|
||||
@@ -127,12 +127,12 @@ class ObjectPrinter:
|
||||
return ArrayPrinter (self.val,class_ns,class_name).to_string ()
|
||||
if class_ns != "":
|
||||
try:
|
||||
gdb_type = gdb.lookup_type ("struct {}.{}".format (class_ns, class_name))
|
||||
gdb_type = gdb.lookup_type ("struct %s.%s".format (class_ns, class_name))
|
||||
except:
|
||||
# Maybe there is no debug info for that type
|
||||
return "{}.{}".format (class_ns, class_name)
|
||||
return "%s.%s".format (class_ns, class_name)
|
||||
#return obj.cast (gdb_type)
|
||||
return "{}.{}".format (class_ns, class_name)
|
||||
return "%s.%s".format (class_ns, class_name)
|
||||
return class_name
|
||||
except:
|
||||
print (sys.exc_info ()[0])
|
||||
@@ -152,9 +152,9 @@ class MonoMethodPrinter:
|
||||
val = self.val.dereference ()
|
||||
klass = val ["klass"].dereference ()
|
||||
class_name = stringify_class_name (klass ["name_space"].string (), klass ["name"].string ())
|
||||
return "\"{}:{} ()\"".format (class_name, val ["name"].string ())
|
||||
return "\"%s:%s ()\"".format (class_name, val ["name"].string ())
|
||||
# This returns more info but requires calling into the inferior
|
||||
#return "\"{}\"".format (gdb.parse_and_eval ("mono_method_full_name ({}, 1)".format (str (int (self.val.cast (gdb.lookup_type ("guint64")))))).string ())
|
||||
#return "\"%s\"".format (gdb.parse_and_eval ("mono_method_full_name (%s, 1)".format (str (int (self.val.cast (gdb.lookup_type ("guint64")))))).string ())
|
||||
|
||||
class MonoClassPrinter:
|
||||
"Print a MonoClass structure"
|
||||
@@ -168,13 +168,13 @@ class MonoClassPrinter:
|
||||
klass = self.val.dereference ()
|
||||
class_name = stringify_class_name (klass ["name_space"].string (), klass ["name"].string ())
|
||||
if klass ["generic_class"].cast (gdb.lookup_type ("guint64")) != 0:
|
||||
class_name = "{}<{}>".format (class_name, str (klass ["generic_class"]["context"]["class_inst"]))
|
||||
class_name = "%s<%s>".format (class_name, str (klass ["generic_class"]["context"]["class_inst"]))
|
||||
if add_quotes:
|
||||
return "\"{}\"".format (class_name)
|
||||
return "\"%s\"".format (class_name)
|
||||
else:
|
||||
return class_name
|
||||
# This returns more info but requires calling into the inferior
|
||||
#return "\"{}\"".format (gdb.parse_and_eval ("mono_type_full_name (&((MonoClass*){})->byval_arg)".format (str (int ((self.val).cast (gdb.lookup_type ("guint64")))))))
|
||||
#return "\"%s\"".format (gdb.parse_and_eval ("mono_type_full_name (&((MonoClass*)%s)->byval_arg)".format (str (int ((self.val).cast (gdb.lookup_type ("guint64")))))))
|
||||
|
||||
def to_string(self):
|
||||
try:
|
||||
@@ -222,7 +222,7 @@ class MonoGenericClassPrinter:
|
||||
method_inst_str = ""
|
||||
if int(method_inst.cast (gdb.lookup_type ("guint64"))) != 0:
|
||||
method_inst_str = str(method_inst)
|
||||
return "{}, [{}], [{}]>".format (container_str, class_inst_str, method_inst_str)
|
||||
return "%s, [%s], [%s]>".format (container_str, class_inst_str, method_inst_str)
|
||||
|
||||
def to_string(self):
|
||||
try:
|
||||
@@ -252,9 +252,9 @@ class MonoTypePrinter:
|
||||
info = str(t ["data"]["generic_class"])
|
||||
|
||||
if info != "":
|
||||
return "{{}, {}}".format (kind, info)
|
||||
return "{%s, %s}".format (kind, info)
|
||||
else:
|
||||
return "{{}}".format (kind)
|
||||
return "{%s}".format (kind)
|
||||
except:
|
||||
#print (sys.exc_info ()[0])
|
||||
#print (sys.exc_info ()[1])
|
||||
@@ -283,7 +283,7 @@ class MonoMethodRgctxPrinter:
|
||||
if i > 0:
|
||||
inst_str = inst_str + ", "
|
||||
inst_str = inst_str + type_printer.to_string ()
|
||||
return "MRGCTX[{}, [{}]]".format (klass_printer.to_string(), inst_str)
|
||||
return "MRGCTX[%s, [%s]]".format (klass_printer.to_string(), inst_str)
|
||||
|
||||
class MonoVTablePrinter:
|
||||
"Print a MonoVTable structure"
|
||||
@@ -298,7 +298,7 @@ class MonoVTablePrinter:
|
||||
klass = vtable ["klass"]
|
||||
klass_printer = MonoClassPrinter (klass)
|
||||
|
||||
return "vtable({})".format (klass_printer.to_string ())
|
||||
return "vtable(%s)".format (klass_printer.to_string ())
|
||||
|
||||
def lookup_pretty_printer(val):
|
||||
t = str (val.type)
|
||||
|
||||
@@ -1,56 +0,0 @@
|
||||
import lldb
|
||||
|
||||
def print_frames(thread, num_frames, current_thread):
|
||||
# TODO: Make output header similar to bt.
|
||||
print '%c thread #%i' % ('*' if current_thread else ' ', thread.idx)
|
||||
|
||||
if current_thread:
|
||||
selected_frame = thread.GetSelectedFrame()
|
||||
|
||||
for frame in thread.frames[:+num_frames]:
|
||||
pc = str(frame.addr)
|
||||
fmt = ' %c %s'
|
||||
var = frame
|
||||
if pc[0] == '0':
|
||||
try:
|
||||
framestr = frame.EvaluateExpression('(char*)mono_pmip((void*)%s)' % pc).summary[1:-1]
|
||||
var = 'frame #%i: %s%s' % (frame.idx, pc, framestr)
|
||||
except:
|
||||
pass
|
||||
|
||||
print fmt % ('*' if current_thread and frame.idx == selected_frame.idx else ' ', var)
|
||||
|
||||
def monobt(debugger, command, result, dict):
|
||||
opts = {'all_bt': False, 'num_frames': None}
|
||||
|
||||
if command == 'all':
|
||||
opts['all_bt'] = True
|
||||
elif command.isdigit():
|
||||
opts['num_frames'] = int(command)
|
||||
elif command != '':
|
||||
print 'error: monobt [<number>|all]'
|
||||
return
|
||||
|
||||
target = debugger.GetSelectedTarget()
|
||||
process = target.process
|
||||
|
||||
if not process.IsValid():
|
||||
print 'error: invalid process'
|
||||
return
|
||||
|
||||
if opts['all_bt']:
|
||||
for thread in process.threads:
|
||||
print_frames(thread, len(thread), process.selected_thread == thread)
|
||||
print ''
|
||||
else:
|
||||
thread = process.selected_thread
|
||||
num_frames = len(thread) if opts['num_frames'] is None else opts['num_frames']
|
||||
print_frames(thread, num_frames, True)
|
||||
|
||||
return None
|
||||
|
||||
def __lldb_init_module (debugger, dict):
|
||||
# This initializer is being run from LLDB in the embedded command interpreter
|
||||
# Add any commands contained in this module to LLDB
|
||||
debugger.HandleCommand('command script add -f monobt.monobt monobt')
|
||||
print '"monobt" command installed'
|
||||
@@ -0,0 +1,6 @@
|
||||
2009-02-19 Rodrigo Kumpera <[email protected]>
|
||||
|
||||
* LockTracerDecoder.cs: Initial version of the lock tracers decoder.
|
||||
|
||||
|
||||
|
||||
@@ -144,8 +144,7 @@ public enum Lock {
|
||||
AssemblyBindingLock,
|
||||
MarshalLock,
|
||||
ClassesLock,
|
||||
LoaderGlobalDataLock,
|
||||
ThreadsLock,
|
||||
LoaderGlobalDataLock
|
||||
}
|
||||
|
||||
public class SimLock
|
||||
@@ -243,24 +242,7 @@ public class SimLock
|
||||
}
|
||||
|
||||
public override string ToString () {
|
||||
switch (kind) {
|
||||
case Lock.LoaderLock:
|
||||
case Lock.IcallLock:
|
||||
case Lock.AssemblyBindingLock:
|
||||
case Lock.MarshalLock:
|
||||
case Lock.ClassesLock:
|
||||
case Lock.LoaderGlobalDataLock:
|
||||
case Lock.ThreadsLock:
|
||||
return String.Format ("{0}", kind);
|
||||
|
||||
case Lock.ImageDataLock:
|
||||
case Lock.DomainLock:
|
||||
case Lock.DomainAssembliesLock:
|
||||
case Lock.DomainJitCodeHashLock:
|
||||
return String.Format ("{0}[{1}]", kind, id);
|
||||
default:
|
||||
return String.Format ("Unknown({0})[{1}]", kind, id);
|
||||
}
|
||||
return String.Format ("{0}", kind);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -329,10 +311,6 @@ public class Trace {
|
||||
"add_record",
|
||||
"mono_locks_lock_acquired",
|
||||
"mono_locks_lock_released",
|
||||
"mono_threads_lock",
|
||||
"mono_threads_unlock",
|
||||
"mono_domain_lock",
|
||||
"mono_domain_unlock",
|
||||
};
|
||||
|
||||
public Trace (string[] fields) {
|
||||
|
||||
@@ -6,4 +6,4 @@ libdir=${exec_prefix}/lib
|
||||
Name: Mono NUnit
|
||||
Description: Mono's version of NUnit
|
||||
Version: @VERSION@
|
||||
Libs: -r:${libdir}/mono/4.5/nunit.core.dll -r:${libdir}/mono/4.5/nunit.core.interfaces.dll -r:${libdir}/mono/4.5/nunit.core.extensions.dll -r:${libdir}/mono/4.5/nunit.framework.dll -r:${libdir}/mono/4.5/nunit.framework.extensions.dll -r:${libdir}/mono/4.5/nunit.mocks.dll -r:${libdir}/mono/4.5/nunit.util.dll -r:${libdir}/mono/4.5/nunit-console-runner.dll
|
||||
Libs: -r:${libdir}/mono/2.0/nunit.core.dll -r:${libdir}/mono/2.0/nunit.core.interfaces.dll -r:${libdir}/mono/2.0/nunit.core.extensions.dll -r:${libdir}/mono/2.0/nunit.framework.dll -r:${libdir}/mono/2.0/nunit.framework.extensions.dll -r:${libdir}/mono/2.0/nunit.mocks.dll -r:${libdir}/mono/2.0/nunit.util.dll -r:${libdir}/mono/2.0/nunit-console-runner.dll
|
||||
+24
-1
@@ -21,8 +21,21 @@ provider mono {
|
||||
|
||||
probe gc__requested (int generation, uintptr_t requested_size, int wait_to_finish);
|
||||
|
||||
probe gc__checkpoint__1 (int generation);
|
||||
probe gc__checkpoint__2 (int generation);
|
||||
probe gc__checkpoint__3 (int generation);
|
||||
probe gc__checkpoint__4 (int generation);
|
||||
probe gc__checkpoint__5 (int generation);
|
||||
probe gc__checkpoint__6 (int generation);
|
||||
probe gc__checkpoint__7 (int generation);
|
||||
probe gc__checkpoint__8 (int generation);
|
||||
probe gc__checkpoint__9 (int generation);
|
||||
|
||||
probe gc__concurrent__start__begin (int generation);
|
||||
probe gc__concurrent__start__end (int generation, long long num_major_objects_marked);
|
||||
probe gc__concurrent__update__finish__begin (int generation, long long num_major_objects_marked);
|
||||
probe gc__concurrent__update__end (int generation, long long num_major_objects_marked);
|
||||
probe gc__concurrent__finish__end (int generation, long long num_major_objects_marked);
|
||||
|
||||
probe gc__sweep__begin (int generation, int full_sweep);
|
||||
probe gc__sweep__end (int generation, int full_sweep);
|
||||
@@ -32,12 +45,19 @@ provider mono {
|
||||
probe gc__world__restart__begin (int generation);
|
||||
probe gc__world__restart__end (int generation);
|
||||
|
||||
probe gc__heap__alloc (uintptr_t addr, uintptr_t len);
|
||||
probe gc__heap__free (uintptr_t addr, uintptr_t len);
|
||||
|
||||
probe gc__locked ();
|
||||
probe gc__unlocked ();
|
||||
|
||||
probe gc__nursery__tlab__alloc (uintptr_t addr, uintptr_t len);
|
||||
probe gc__nursery__obj__alloc (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
|
||||
|
||||
probe gc__major__obj__alloc__large (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
|
||||
probe gc__major__obj__alloc__pinned (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
|
||||
probe gc__major__obj__alloc__degraded (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
|
||||
probe gc__major__obj__alloc__mature (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
|
||||
|
||||
/* Can be nursery->nursery, nursery->major or major->major */
|
||||
probe gc__obj__moved (uintptr_t dest, uintptr_t src, int dest_gen, int src_gen, uintptr_t size, char *ns_name, char *class_name);
|
||||
@@ -50,10 +70,13 @@ provider mono {
|
||||
probe gc__finalize__enqueue (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name, int generation, int is_critical);
|
||||
probe gc__finalize__invoke (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
|
||||
|
||||
probe gc__weak__update (uintptr_t ref_addr, uintptr_t new_addr, uintptr_t size, char *ns_name, char *class_name, int track);
|
||||
probe gc__weak__update (uintptr_t ref_addr, uintptr_t old_addr, uintptr_t new_addr, uintptr_t size, char *ns_name, char *class_name, int track);
|
||||
|
||||
probe gc__global__remset__add (uintptr_t ref_addr, uintptr_t obj_addr, uintptr_t size, char *ns_name, char *class_name);
|
||||
probe gc__obj__cemented (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
|
||||
|
||||
probe gc__internal__alloc (uintptr_t addr, uintptr_t size, int type);
|
||||
probe gc__internal__dealloc (uintptr_t add, uintptr_t size, int type);
|
||||
};
|
||||
|
||||
#pragma D attributes Evolving/Evolving/Common provider mono provider
|
||||
|
||||
@@ -0,0 +1,147 @@
|
||||
2009-08-11 Gonzalo Paniagua Javier <[email protected]>
|
||||
|
||||
* DefaultWsdlHelpGenerator.aspx: the 'Message Layout' can now handle
|
||||
self-referencing types. Fixes bug #529353.
|
||||
|
||||
2009-08-05 Atsushi Enomoto <[email protected]>
|
||||
|
||||
* web.config: add WCF assemblies as references at compilation.
|
||||
* machine.config: add some missing WCF sections (new in 3.5).
|
||||
|
||||
2009-05-28 Atsushi Enomoto <[email protected]>
|
||||
|
||||
* machine.config: fix WCF diagnostics section name.
|
||||
|
||||
2009-03-31 Marek Habersack <[email protected]>
|
||||
|
||||
* DefaultWsdlHelpGenerator.aspx: the link element in <head> must
|
||||
be created using Response.Write, as the code expression in the
|
||||
href attribute is otherwise treated verbatim. This is the same as
|
||||
with .NET. Fixes bug #490497
|
||||
|
||||
2009-03-27 Gonzalo Paniagua Javier <[email protected]>
|
||||
|
||||
* DefaultWsdlHelpGenerator.aspx: disable the test form
|
||||
when only Soap is supported.
|
||||
Bug #342073 fixed.
|
||||
|
||||
2009-01-23 Atsushi Enomoto <[email protected]>
|
||||
|
||||
* web.config : added .svc handler.
|
||||
|
||||
2009-01-07 Kornél Pál <[email protected]>
|
||||
|
||||
* DefaultWsdlHelpGenerator.aspx: Move <script> at the end of <head> that
|
||||
will make Visual Studio recognize the web service disco reference.
|
||||
|
||||
Contributed under MIT/X11 license.
|
||||
|
||||
2008-12-03 Marek Habersack <[email protected]>
|
||||
|
||||
* machine.config: rename serviceModelHostingEnvironment to
|
||||
serviceHostingEnvironment.
|
||||
|
||||
2008-11-20 Gonzalo Paniagua Javier <[email protected]>
|
||||
|
||||
* machine.config: in 2.0, there's no <connectionManagement> section
|
||||
here. Bug #445991 fixed.
|
||||
|
||||
2008-11-14 Gonzalo Paniagua Javier <[email protected]>
|
||||
|
||||
* DefaultWsdlHelpGenerator.aspx: use javascript instead of
|
||||
HttpWebRequest to avoid a deadlock if the web service uses Session.
|
||||
Bug #444343 fixed.
|
||||
|
||||
2008-10-09 Gonzalo Paniagua Javier <[email protected]>
|
||||
|
||||
* web.config: default values for httpRuntime are different in 2.0
|
||||
|
||||
2008-10-09 Marek Habersack <[email protected]>
|
||||
|
||||
* web.config: added the default monoSettings section which works around
|
||||
an incompatibility between mcs and csc, mentioned in bug #433806
|
||||
|
||||
* machine.config: added definition of the monoSettings section to
|
||||
the system.web group
|
||||
|
||||
2008-10-06 Marek Habersack <[email protected]>
|
||||
|
||||
* machine.config: added entries to ignore the mobileControls and
|
||||
deviceFilters sections.
|
||||
|
||||
2008-09-02 Marek Habersack <[email protected]>
|
||||
|
||||
* web.config: removed System.Web.Extensions.dll from the assemblies
|
||||
(reverting r112073) - it would break all the ASP.NET applications
|
||||
which use System.Web.Extensions other than 3.5.0.0
|
||||
|
||||
2008-09-06 Daniel Morgan <[email protected]>
|
||||
|
||||
* machine.config: added Mono.Data.SybaseClient
|
||||
to DbProviderFactories section.
|
||||
|
||||
2008-09-02 Atsushi Enomoto <[email protected]>
|
||||
|
||||
* web.config: added System.Web.Extensions.dll to assemblies.
|
||||
|
||||
2008-08-28 Zoltan Varga <[email protected]>
|
||||
|
||||
* machine.config: Fix syntax error.
|
||||
|
||||
2008-03-23 Dean Brettle <[email protected]>
|
||||
|
||||
* Makefile.am: added Browsers/Compat.browser
|
||||
|
||||
2008-02-29 Marek Habersack <[email protected]>
|
||||
|
||||
* machine.config: added an entry to ignore the browserCaps section.
|
||||
|
||||
2007-12-15 Marek Habersack <[email protected]>
|
||||
|
||||
* web.config: compilation/compilers are no longer necessary.
|
||||
|
||||
2007-12-08 Marek Habersack <[email protected]>
|
||||
|
||||
* machine.config: updated the LocalSqlServer connection string to
|
||||
match MS.NET and added a new connection string, LocalSqliteServer,
|
||||
to be used by default on Unix.
|
||||
Updated the AspNetSqlMembershipProvider definition to match
|
||||
MS.NET.
|
||||
|
||||
* settings.map: added
|
||||
|
||||
* Makefile.am: added settings.map
|
||||
|
||||
2007-10-17 Atsushi Enomoto <[email protected]>
|
||||
|
||||
* web.config, machine.config: moved webSerices section from former
|
||||
to latter.
|
||||
|
||||
2007-09-05 Atsushi Enomoto <[email protected]>
|
||||
|
||||
* machine.config : added WCF sectionGroups.
|
||||
|
||||
2007-09-04 Marek Habersack <[email protected]>
|
||||
|
||||
* machine.config: added an entry to ignore the <system.webServer>
|
||||
section. Fixes bug #82535
|
||||
|
||||
2007-07-03 Marek Habersack <[email protected]>
|
||||
|
||||
* DefaultWsdlHelpGenerator.aspx: make head server-side, for the
|
||||
service generator to run on sites which use stylesheet themes
|
||||
configured in web.config. Fixes bug #81994
|
||||
|
||||
2007-05-01 Marek Habersack <[email protected]>
|
||||
|
||||
* machine.config: added standard data provider factories, or
|
||||
otherwise the SqlDataSource tests will fail.
|
||||
|
||||
2007-04-27 Atsushi Enomoto <[email protected]>
|
||||
|
||||
* DefaultWsdlHelpGenerator.aspx :
|
||||
ProfileViolations could be null, when there is no Binding. So,
|
||||
don't omit null check.
|
||||
|
||||
Stop your bad habit of missing ChangeLog. Former changes (as long
|
||||
as logged) can be seen in ../../ChangeLog.
|
||||
@@ -0,0 +1,9 @@
|
||||
2009-08-06 Atsushi Enomoto <[email protected]>
|
||||
|
||||
* web.config: add WCF assemblies as references at compilation.
|
||||
* machine.config: add some missing WCF sections (new in 3.5).
|
||||
|
||||
2009-07-24 Jb Evain <[email protected]>
|
||||
|
||||
* Initial import of the net_4_0 specific files.
|
||||
|
||||
@@ -13,14 +13,11 @@
|
||||
<section name="startup" type="System.Configuration.IgnoreSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" allowLocation="false"/>
|
||||
<section name="system.codedom" type="System.CodeDom.Compiler.CodeDomConfigurationHandler, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<section name="system.data" type="System.Data.Common.DbProviderFactoriesConfigurationHandler, System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<section name="system.diagnostics" type="System.Diagnostics.SystemDiagnosticsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<section name="system.diagnostics" type="System.Diagnostics.DiagnosticsConfigurationHandler, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<section name="system.runtime.remoting" type="System.Configuration.IgnoreSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowLocation="false"/>
|
||||
<section name="system.windows.forms" type="System.Windows.Forms.WindowsFormsSection, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<section name="windows" type="System.Configuration.IgnoreSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" allowLocation="false" />
|
||||
<section name="strongNames" type="System.Configuration.IgnoreSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowLocation="false"/>
|
||||
<sectionGroup name="system.runtime.serialization" type="System.Runtime.Serialization.Configuration.SerializationSectionGroup, System.Runtime.Serialization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<section name="dataContractSerializer" type="System.Runtime.Serialization.Configuration.DataContractSerializerSection, System.Runtime.Serialization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
|
||||
</sectionGroup>
|
||||
<sectionGroup name="system.web" type="System.Web.Configuration.SystemWebSectionGroup, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<section name="anonymousIdentification" type="System.Web.Configuration.AnonymousIdentificationSection, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" allowDefinition="MachineToApplication"/>
|
||||
<section name="authentication" type="System.Web.Configuration.AuthenticationSection, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" allowDefinition="MachineToApplication"/>
|
||||
|
||||
+133
@@ -0,0 +1,133 @@
|
||||
2010-04-06 Andreia Gaita <[email protected]>
|
||||
|
||||
* Makefile.am: fix distcheck - several targets get built on the
|
||||
srcdir, which has no write permissions on make distcheck, so make
|
||||
sure permissions are set
|
||||
|
||||
2009-12-22 Jo Shields <[email protected]>
|
||||
* HtmlAgilityPack/LICENSE: Include upstream license (Ms-PL) since the
|
||||
file headers don't specify it
|
||||
|
||||
2009-12-22 Jo Shields <[email protected]>
|
||||
|
||||
* HtmlAgilityPack/*: Bundle HtmlAgilityPack 1.4~beta2 from
|
||||
http://www.codeplex.com/htmlagilitypack in source form.
|
||||
|
||||
* AgilityPack.dll: Remove binary assembly, use source instead.
|
||||
|
||||
* docs.make Makefile.am README: Reflect above changes
|
||||
|
||||
2009-02-12 Zoltan Varga <[email protected]>
|
||||
|
||||
* Makefile.am (EXTRA_DIST): Remove removed files.
|
||||
|
||||
* README: Point to the documentation on the wiki.
|
||||
|
||||
* call-sites.txt: Remove this, its contents is in jit-trampolines.
|
||||
|
||||
* memory-management.txt thread-safety.txt aot-compiler.txt jit-regalloc
|
||||
exception-handling.txt: Remove documents which are now on the wiki.
|
||||
|
||||
2009-02-11 Rodrigo Kumpera <[email protected]>
|
||||
|
||||
* thread-safety.txt: Improve the docs about image lock.
|
||||
|
||||
2009-02-11 Rodrigo Kumpera <[email protected]>
|
||||
|
||||
* thread-safety.txt: Document the new image lock.
|
||||
|
||||
2008-12-12 Mark Probst <[email protected]>
|
||||
|
||||
* mini-porting.txt: Added some details about function descriptors
|
||||
and emulated opcodes.
|
||||
|
||||
2008-12-08 Jonathan Pryor <[email protected]>
|
||||
|
||||
* mono-file-formats.source, mono-tools.source: Place these under the
|
||||
new "Commands and Files" node, and remove nay intermediate nodes.
|
||||
|
||||
2008-11-20 Jonathan Pryor <[email protected]>
|
||||
|
||||
* Makefile.am (sources_DATA): Add mono-file-formats.source,
|
||||
mono-tools.source.
|
||||
|
||||
2008-11-20 Raja R Harinath <[email protected]>
|
||||
|
||||
Remove unnecessary rebuilds of the html directory
|
||||
* docs.make (monoapi.zip): Make slightly more unforgiving, by
|
||||
using '&&' instead of ';' to sequence commands.
|
||||
(mono-tools.zip, mono-file-formats.zip): Likewise.
|
||||
* Makefile.am (monoapi.zip, mono-tools.zip, mono-fileformats.zip):
|
||||
Likewise.
|
||||
(convert.exe): Don't depend on Makefile.am or docs.make.
|
||||
|
||||
2008-11-19 Raja R Harinath <[email protected]>
|
||||
|
||||
Fix srcdir != builddir, and add idiom for multi-output commands
|
||||
* docs.make (monoapi.zip): Handle the case where 'monoapi.tree'
|
||||
exists but 'monoapi.zip' doesn't. IOW, we should rebuild
|
||||
monoapi.zip with 'rm monoapi.zip; make'.
|
||||
(mono-tools.zip, mono-file-formats.zip): Likewise.
|
||||
* Makefile.am (monoapi.zip, mono-tools.zip, mono-fileformats.zip):
|
||||
Likewise.
|
||||
(monoapi.tree): Don't use $< in an explicit rule.
|
||||
(mono-tools.tree, mono-file-formats.tree): Likewise.
|
||||
|
||||
2008-11-18 Jonathan Pryor <[email protected]>
|
||||
|
||||
* Makefile.am (EXTRA_DIST): Add mono-file-formats{.config,.source} and
|
||||
mono-tools{.config,.source} (fixes the build).
|
||||
|
||||
2008-11-18 Jonathan Pryor <[email protected]>
|
||||
|
||||
* docs.make, Makefile.am: Build mono-file-formats{.tree,.zip},
|
||||
mono-tool{.tree,.zip} files.
|
||||
* mono-file-formats.config, mono-tools.config: Alter paths to man
|
||||
pages so that they're valid for building from mono/docs.
|
||||
* monoapi.make: Rename to docs.make.
|
||||
|
||||
2008-11-01 Raja R Harinath <[email protected]>
|
||||
|
||||
* Makefile.am: Clean up for srcdir != builddir.
|
||||
(deploy/.stamp): Compute location of 'mono-wrapper' and pass to exdoc.
|
||||
* exdoc (mono-wrapper): Use $runtimedir to look for 'mono-wrapper'.
|
||||
|
||||
2008-10-31 Jonathan Pryor <[email protected]>
|
||||
|
||||
* check, Makefile.am (EXTRA_DIST): Rename to check-exports. This was
|
||||
needed to fix `make distdir...`, because (1) with a file named
|
||||
`check` which (2) was listed in $(EXTRA_DIST), while (3) `check` is
|
||||
ALSO a .PHONY target, this caused make to look for the `check` file,
|
||||
not find it due to (3), and then proceed to try to build convert.exe
|
||||
from convert.cs...for reasons I don't care about. This obviously
|
||||
can't work during `make distdir`, as mcs hasn't been built yet, thus
|
||||
leading to pain, suffering, and a broken build.
|
||||
|
||||
2008-10-30 Jonathan Pryor <[email protected]>
|
||||
|
||||
* . (svn:ignore), deploy (svn:ignore): Ignore generated files.
|
||||
* AgilityPack.dll, api-style.css, ChangeLog, check, check-coverage,
|
||||
convert.cs, current-api, deploy, documented, exdoc, ignore,
|
||||
mono-api-metadata.html, monoapi.source, produce-lists, public,
|
||||
public-api, README, sources, toc.xml, TODO, wapi: Copy from
|
||||
../mono/docscripts.
|
||||
* exdoc: Use the in-tree mono program to run convert.exe.
|
||||
* Makefile.am: Mention files to clean/distribute; extract
|
||||
documentation (with exdoc) and then assemble documentation (with
|
||||
monoapi.make's assemble target) for use by monodoc.
|
||||
* monoapi.make: Added; Makefile to use mcs' buid/rules.make to compile
|
||||
convert.cs and assemble documentation. (This is a separate file so
|
||||
that we can include mcs' build/rules.make, which needs topdir set to
|
||||
behave properly BUT must be $(mcs_topdir) from Makefile.am's
|
||||
perspective.)
|
||||
* monoapi.source: Add a /monodoc/node element for use with monodoc 2.2.
|
||||
|
||||
2006-11-19 Miguel de Icaza <[email protected]>
|
||||
|
||||
* exdoc: Move to use CSS instead of tables, this will break
|
||||
GtkHTML rendering.
|
||||
|
||||
* ignore: Updated with more hidden APIs.
|
||||
|
||||
* Bunch of documentation work.
|
||||
|
||||
+17
-7
@@ -14,12 +14,16 @@ ASSEMBLED_DOCS = \
|
||||
EXTRA_DIST = \
|
||||
abc-removal.txt \
|
||||
api-style.css \
|
||||
assembly-bundle \
|
||||
check-exports \
|
||||
check-coverage \
|
||||
convert.cs \
|
||||
current-api \
|
||||
deploy \
|
||||
docs.make \
|
||||
documented \
|
||||
embedded-api \
|
||||
exceptions \
|
||||
exdoc \
|
||||
file-share-modes \
|
||||
gc-issues \
|
||||
@@ -31,29 +35,35 @@ EXTRA_DIST = \
|
||||
jit-imt \
|
||||
jit-thoughts \
|
||||
jit-trampolines \
|
||||
local-regalloc.txt \
|
||||
magic.diff \
|
||||
mini-doc.txt \
|
||||
mono-api-metadata.html \
|
||||
mono-file-formats.config\
|
||||
mono-file-formats.source\
|
||||
mono_handle_d \
|
||||
mono-tools.config \
|
||||
mono-tools.source \
|
||||
monoapi.source \
|
||||
new-regalloc \
|
||||
object-layout \
|
||||
opcode-decomp.txt \
|
||||
precise-gc \
|
||||
produce-lists \
|
||||
public \
|
||||
public-api \
|
||||
README \
|
||||
release-notes-1.0.html \
|
||||
remoting \
|
||||
ssapre.txt \
|
||||
stack-alignment \
|
||||
stack-overflow.txt \
|
||||
threading \
|
||||
toc.xml \
|
||||
TODO \
|
||||
tree-mover.txt \
|
||||
unmanaged-calls
|
||||
|
||||
-include $(mcs_topdir)/build/config.make
|
||||
|
||||
CLASS=$(mcs_topdir)/class/lib/$(DEFAULT_PROFILE)
|
||||
|
||||
dist-hook:
|
||||
$(mkdir_p) $(distdir)/sources
|
||||
$(mkdir_p) $(distdir)/svgs
|
||||
@@ -89,14 +99,14 @@ mono-file-formats.tree: $(srcdir)/docs.make $(srcdir)/Makefile.am $(srcdir)/depl
|
||||
deploy/.stamp: convert.exe Makefile.am
|
||||
$(mkdir_p) html
|
||||
runtimedir=`cd ../runtime && pwd`; export runtimedir; \
|
||||
MONO_PATH=$(CLASS) perl $(srcdir)/exdoc -h $(srcdir) -t . $(srcdir)/../mono/*/*.c
|
||||
MONO_PATH=../mcs/class/lib/net_4_5 perl $(srcdir)/exdoc -h $(srcdir) -t . $(srcdir)/../mono/*/*.c
|
||||
touch $@
|
||||
|
||||
extract: deploy/.stamp
|
||||
|
||||
convert.exe: convert.cs AgilityPack.dll
|
||||
$(TOOL_MAKE) convert.exe
|
||||
$(TOOL_MAKE) PROFILE=net_4_5 convert.exe
|
||||
|
||||
AgilityPack.dll:
|
||||
$(TOOL_MAKE) AgilityPack.dll
|
||||
$(TOOL_MAKE) PROFILE=net_4_5 AgilityPack.dll
|
||||
|
||||
+36
-176
@@ -1,180 +1,40 @@
|
||||
.mapi-docs {
|
||||
line-height: 1.5;
|
||||
padding-left: 2em;
|
||||
padding-right: 2em;
|
||||
}
|
||||
.mapi-docs p {
|
||||
max-width: 60em;
|
||||
}
|
||||
.mapi-docs .mapi-body {
|
||||
max-width: 60em;
|
||||
}
|
||||
.mapi-docs code {
|
||||
border: 1px solid rgba(214,214,214,1);
|
||||
background-color: rgba(249,249,249,1);
|
||||
padding: 0.1em 0.5em;
|
||||
}
|
||||
.mapi-description code {
|
||||
font-family: "Consolas", "Courier", monospace;
|
||||
border: 1px solid rgba(214,214,214,1);
|
||||
background-color: rgba(249,249,249,1);
|
||||
padding: 0.1em 0.2em;
|
||||
}
|
||||
h3 {
|
||||
font-size: 18px;
|
||||
padding-bottom: 4pt;
|
||||
border-bottom: 2px solid #dddddd;
|
||||
}
|
||||
|
||||
.api {
|
||||
border: 1px solid;
|
||||
padding: 10pt;
|
||||
margin: 10pt;
|
||||
}
|
||||
|
||||
.mapi-header {
|
||||
padding: 0 0 5pt 5pt;
|
||||
margin: 10pt;
|
||||
white-space: pre;
|
||||
font-family: monospace;
|
||||
border: 1px solid rgba(233,233,233,1);
|
||||
background-color: rgba(249,249,249,1);
|
||||
}
|
||||
.api-entry {
|
||||
border-bottom: none;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.mapi-code {
|
||||
padding: 5pt 5pt;
|
||||
margin: 10pt;
|
||||
white-space: pre;
|
||||
font-family: monospace;
|
||||
border: 1px solid rgba(233,233,233,1);
|
||||
background-color: rgba(249,249,249,1);
|
||||
}
|
||||
.prototype {
|
||||
border: 1px solid;
|
||||
background-color: #f2f2f2;
|
||||
padding: 5pt;
|
||||
margin-top: 5pt;
|
||||
margin-bottom: 5pt;
|
||||
}
|
||||
|
||||
.mapi-code:first-line {
|
||||
line-height: 0px;
|
||||
}
|
||||
|
||||
.mapi-entry code {
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
}
|
||||
.header {
|
||||
border: 1px solid;
|
||||
padding: 0 0 5pt 5pt;
|
||||
margin: 10pt;
|
||||
white-space: pre;
|
||||
font-family: monospace;
|
||||
}
|
||||
|
||||
.mapi-parameters {
|
||||
border-collapse: collapse;
|
||||
border-spacing: 0;
|
||||
empty-cells: hide;
|
||||
border: 0;
|
||||
margin: 5px 0 26px;
|
||||
}
|
||||
|
||||
.mapi-parameters td {
|
||||
border: 1px solid rgba(214,214,214,1);
|
||||
border-left-style: none;
|
||||
padding: 5px 25px 5px 10px;
|
||||
}
|
||||
|
||||
.mapi-parameters tr>td:last-child {
|
||||
border-right: 0;
|
||||
}
|
||||
|
||||
.mapi-parameters td:first-of-type {
|
||||
text-align: right;
|
||||
padding: 7px;
|
||||
vertical-align: top;
|
||||
word-break: normal;
|
||||
width: 40px;
|
||||
}
|
||||
|
||||
.mapi-parameters tr:last-child>td {
|
||||
border-bottom: 0;
|
||||
}
|
||||
|
||||
.mapi-parameters tr:first-child>td {
|
||||
border-top: 0;
|
||||
}
|
||||
|
||||
.mapi-parameters tr td:first-of-type {
|
||||
text-align: right;
|
||||
padding: 7px;
|
||||
vertical-align: top;
|
||||
word-break: normal;
|
||||
width: 40px;
|
||||
}
|
||||
|
||||
.mapi {
|
||||
left: -25px;
|
||||
margin: 0;
|
||||
padding: 13px 25px 0;
|
||||
position: relative;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.mapi-description {
|
||||
background: rgba(249,249,249,1);
|
||||
border-bottom: 1px solid rgba(233,233,233,1);
|
||||
left: -25px;
|
||||
margin: 0;
|
||||
padding: 13px 25px 0;
|
||||
position: relative;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.mapi-entry {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.mapi-docs {
|
||||
}
|
||||
|
||||
.mapi-prototype {
|
||||
border-left: 5px solid rgba(205,233,244,1);
|
||||
padding: .5em;
|
||||
margin-top: 5pt;
|
||||
margin-bottom: 5pt;
|
||||
font-family: "Consolas", "Courier", monospace;
|
||||
display: block;
|
||||
overflow: auto;
|
||||
background-color: #f9f9f9;
|
||||
}
|
||||
|
||||
.mapi-declaration {
|
||||
margin-top: 21px;
|
||||
}
|
||||
|
||||
.mapi-section {
|
||||
font-size: smaller;
|
||||
font-weight: bold;
|
||||
margin-top: 21px;
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
.mapi-strike {
|
||||
text-decoration: line-through;
|
||||
}
|
||||
|
||||
.mapi-deprecated {
|
||||
color: red;
|
||||
}
|
||||
|
||||
.mapi-ptr-container {
|
||||
background: white;
|
||||
border-bottom: 1px solid rgba(233,233,233,1);
|
||||
left: -25px;
|
||||
padding-left: 25px;
|
||||
padding-right: 25px;
|
||||
padding-bottom: 13px;
|
||||
position: relative;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.mapi-ptr {
|
||||
background: rgba(249,249,249,1);
|
||||
border-left: 1px solid rgba(233,233,233,1);
|
||||
border-top: 1px solid rgba(233,233,233,1);
|
||||
height: 12px;
|
||||
left: 37px;
|
||||
top: -7px;
|
||||
-webkit-transform: rotate(45deg);
|
||||
-moz-transform: rotate(45deg);
|
||||
-o-transform: rotate(45deg);
|
||||
transform: rotate(45deg);
|
||||
position: absolute;
|
||||
width: 12px;
|
||||
}
|
||||
|
||||
.mapi-height-container {
|
||||
left: -25px;
|
||||
padding: 0 25px;
|
||||
position: relative;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.code {
|
||||
border: 1px solid;
|
||||
padding: 0 0 5pt 5pt;
|
||||
margin: 10pt;
|
||||
white-space: pre;
|
||||
font-family: monospace;
|
||||
}
|
||||
@@ -0,0 +1,57 @@
|
||||
|
||||
HOWTO bundle assemblies inside the mono runtime.
|
||||
Paolo Molaro ([email protected])
|
||||
|
||||
* Intent
|
||||
|
||||
Bundling assemblies inside the mono runtime may be useful for a number
|
||||
of reasons:
|
||||
|
||||
* creating a standalone complete runtime that can be more easily
|
||||
distributed
|
||||
|
||||
* having an application run against a known set of assemblies
|
||||
that has been tested
|
||||
|
||||
Of course, there are drawbacks, too: if there has been fixes
|
||||
to the assemblies, replacing them means recompiling the
|
||||
runtime as well and if there are other mono apps, unless they
|
||||
use the same mono binary, there will be less opportunities for
|
||||
the operating system to optimize memory usage. So use this
|
||||
feature only when really needed.
|
||||
|
||||
* Creating the Bundle
|
||||
|
||||
To bundle a set of assemblies, you need to create a file that
|
||||
lists the assembly names and the relative files. Empty lines
|
||||
and lines starting with # are ignored:
|
||||
|
||||
== cut cut ==
|
||||
# Sample bundle template
|
||||
mscorlib: /path/to/mscorlib/assembly.dll
|
||||
myapp: /path/to/myapp.exe
|
||||
== cut cut ==
|
||||
|
||||
Next you need to build the mono runtime using a special configure option:
|
||||
|
||||
./configure --with-bundle=/path/to/bundle/template
|
||||
|
||||
The path to the template should be an absolute path.
|
||||
|
||||
The script metadata/make-bundle.pl will take the specifie
|
||||
assemblies and embed them inside the runtime where the loading
|
||||
routines can find them before searching for them on disk.
|
||||
|
||||
* Open Issues
|
||||
|
||||
There are still two issues to solve:
|
||||
|
||||
* config files: sometimes they are needed but they are
|
||||
not yet bundled inside the library ()
|
||||
|
||||
* building with the included libgc makes it not
|
||||
possible to build a mono binary statically linked to
|
||||
libmono: this needs to be fixed to make bundles
|
||||
really useful.
|
||||
|
||||
|
||||
@@ -0,0 +1,953 @@
|
||||
dlfree
|
||||
dlmalloc
|
||||
dlmemalign
|
||||
free_list_index_of
|
||||
g_printerr
|
||||
g_ptr_array_remove_fast
|
||||
invoke_protected_memory_method
|
||||
mini_debugger_init
|
||||
mini_debugger_main
|
||||
mini_debugger_set_attach_ok
|
||||
mini_debug_running_inside_mdb
|
||||
mini_emit_initobj
|
||||
mini_emit_stobj
|
||||
mono_add_internal_call
|
||||
mono_aot_register_globals
|
||||
mono_aot_register_module
|
||||
mono_array_addr_with_size
|
||||
mono_array_class_get
|
||||
mono_array_clone
|
||||
mono_array_element_size
|
||||
mono_array_length
|
||||
mono_array_new
|
||||
mono_array_new_full
|
||||
mono_array_new_specific
|
||||
mono_assemblies_cleanup
|
||||
mono_assembly_close
|
||||
mono_assembly_get_image
|
||||
mono_assembly_get_main
|
||||
mono_assembly_get_object
|
||||
mono_assembly_getrootdir
|
||||
mono_assembly_load
|
||||
mono_assembly_loaded
|
||||
mono_assembly_loaded_full
|
||||
mono_assembly_load_full
|
||||
mono_assembly_name_free
|
||||
mono_assembly_name_get_culture
|
||||
mono_assembly_name_get_name
|
||||
mono_assembly_name_get_pubkeytoken
|
||||
mono_assembly_name_get_version
|
||||
mono_assembly_name_new
|
||||
mono_assembly_names_equal
|
||||
mono_assembly_open
|
||||
mono_bitset_alloc_size
|
||||
mono_bitset_clear
|
||||
mono_bitset_clear_all
|
||||
mono_bitset_clone
|
||||
mono_bitset_copyto
|
||||
mono_bitset_count
|
||||
mono_bitset_equal
|
||||
mono_bitset_find_first
|
||||
mono_bitset_find_first_unset
|
||||
mono_bitset_find_last
|
||||
mono_bitset_find_start
|
||||
mono_bitset_foreach
|
||||
mono_bitset_free
|
||||
mono_bitset_intersection
|
||||
mono_bitset_intersection_2
|
||||
mono_bitset_invert
|
||||
mono_bitset_mem_new
|
||||
mono_bitset_new
|
||||
mono_bitset_set
|
||||
mono_bitset_set_all
|
||||
mono_bitset_size
|
||||
mono_bitset_sub
|
||||
mono_bitset_test
|
||||
mono_bitset_test_bulk
|
||||
mono_bitset_union
|
||||
mono_bounded_array_class_get
|
||||
mono_breakpoint_clean_code
|
||||
mono_check_corlib_version
|
||||
mono_class_array_element_size
|
||||
mono_class_data_size
|
||||
mono_class_describe_statics
|
||||
mono_class_enum_basetype
|
||||
mono_class_from_generic_parameter
|
||||
mono_class_from_mono_type
|
||||
mono_class_from_name
|
||||
mono_class_from_name_case
|
||||
mono_class_from_typeref
|
||||
mono_class_get
|
||||
mono_class_get_byref_type
|
||||
mono_class_get_element_class
|
||||
mono_class_get_events
|
||||
mono_class_get_event_token
|
||||
mono_class_get_field
|
||||
mono_class_get_field_from_name
|
||||
mono_class_get_fields
|
||||
mono_class_get_field_token
|
||||
mono_class_get_flags
|
||||
mono_class_get_full
|
||||
mono_class_get_image
|
||||
mono_class_get_interfaces
|
||||
mono_class_get_method_from_name
|
||||
mono_class_get_method_from_name_flags
|
||||
mono_class_get_methods
|
||||
mono_class_get_name
|
||||
mono_class_get_namespace
|
||||
mono_class_get_nested_types
|
||||
mono_class_get_nesting_type
|
||||
mono_class_get_parent
|
||||
mono_class_get_properties
|
||||
mono_class_get_property_from_name
|
||||
mono_class_get_property_token
|
||||
mono_class_get_rank
|
||||
mono_class_get_type
|
||||
mono_class_get_type_token
|
||||
mono_class_inflate_generic_method
|
||||
mono_class_inflate_generic_type
|
||||
mono_class_init
|
||||
mono_class_instance_size
|
||||
mono_class_interface_offset
|
||||
mono_class_is_assignable_from
|
||||
mono_class_is_enum
|
||||
mono_class_is_subclass_of
|
||||
mono_class_is_valid_enum
|
||||
mono_class_is_valuetype
|
||||
mono_class_min_align
|
||||
mono_class_name_from_token
|
||||
mono_class_num_events
|
||||
mono_class_num_fields
|
||||
mono_class_num_methods
|
||||
mono_class_num_properties
|
||||
mono_class_value_size
|
||||
mono_class_vtable
|
||||
mono_cli_rva_image_map
|
||||
mono_code_manager_commit
|
||||
mono_code_manager_destroy
|
||||
mono_code_manager_foreach
|
||||
mono_code_manager_invalidate
|
||||
mono_code_manager_new
|
||||
mono_code_manager_new_dynamic
|
||||
mono_code_manager_reserve
|
||||
mono_code_manager_reserve_align
|
||||
mono_code_manager_set_read_only
|
||||
mono_code_manager_size
|
||||
mono_compile_method
|
||||
mono_config_for_assembly
|
||||
mono_config_parse
|
||||
mono_config_parse_memory
|
||||
mono_config_string_for_assembly_file
|
||||
mono_context_get
|
||||
mono_context_get_desc
|
||||
mono_context_set
|
||||
mono_counters_cleanup
|
||||
mono_counters_dump
|
||||
mono_counters_enable
|
||||
mono_counters_register
|
||||
mono_custom_attrs_construct
|
||||
mono_custom_attrs_free
|
||||
mono_custom_attrs_from_assembly
|
||||
mono_custom_attrs_from_class
|
||||
mono_custom_attrs_from_event
|
||||
mono_custom_attrs_from_field
|
||||
mono_custom_attrs_from_index
|
||||
mono_custom_attrs_from_method
|
||||
mono_custom_attrs_from_param
|
||||
mono_custom_attrs_from_property
|
||||
mono_custom_attrs_get_attr
|
||||
mono_custom_attrs_has_attr
|
||||
mono_debug_add_method
|
||||
_mono_debug_address_from_il_offset
|
||||
mono_debug_close_image
|
||||
mono_debug_close_mono_symbol_file
|
||||
mono_debug_domain_create
|
||||
mono_debug_domain_unload
|
||||
mono_debug_find_method
|
||||
mono_debug_free_source_location
|
||||
mono_debugger_abort_runtime_invoke
|
||||
mono_debugger_breakpoint_callback
|
||||
mono_debugger_call_exception_handler
|
||||
mono_debugger_check_breakpoints
|
||||
mono_debugger_check_interruption
|
||||
mono_debugger_check_runtime_version
|
||||
mono_debugger_class_initialized
|
||||
mono_debugger_event
|
||||
mono_debugger_event_create_appdomain
|
||||
mono_debugger_event_unload_appdomain
|
||||
mono_debugger_extended_notification
|
||||
mono_debugger_handle_exception
|
||||
mono_debugger_insert_breakpoint
|
||||
mono_debugger_insert_breakpoint_full
|
||||
mono_debugger_insert_method_breakpoint
|
||||
mono_debugger_lock
|
||||
mono_debugger_method_has_breakpoint
|
||||
MONO_DEBUGGER__notification_function
|
||||
mono_debugger_register_class_init_callback
|
||||
mono_debugger_remove_breakpoint
|
||||
mono_debugger_remove_class_init_callback
|
||||
mono_debugger_remove_method_breakpoint
|
||||
mono_debugger_run_finally
|
||||
mono_debugger_runtime_invoke
|
||||
mono_debugger_thread_cleanup
|
||||
mono_debugger_thread_created
|
||||
_mono_debugger_throw_exception
|
||||
mono_debugger_trampoline_compiled
|
||||
_mono_debugger_unhandled_exception
|
||||
mono_debugger_unlock
|
||||
mono_debug_il_offset_from_address
|
||||
mono_debug_list_add
|
||||
mono_debug_list_remove
|
||||
mono_debug_lookup_locals
|
||||
mono_debug_lookup_method
|
||||
mono_debug_lookup_method_addresses
|
||||
mono_debug_lookup_source_location
|
||||
mono_debug_open_image_from_memory
|
||||
mono_debug_open_mono_symbols
|
||||
mono_debug_print_stack_frame
|
||||
mono_debug_print_vars
|
||||
mono_debug_symfile_get_line_numbers
|
||||
mono_debug_symfile_lookup_locals
|
||||
mono_debug_symfile_lookup_location
|
||||
mono_debug_symfile_lookup_method
|
||||
mono_debug_using_mono_debugger
|
||||
mono_declsec_flags_from_assembly
|
||||
mono_declsec_flags_from_class
|
||||
mono_declsec_flags_from_method
|
||||
mono_declsec_get_assembly_action
|
||||
mono_declsec_get_class_action
|
||||
mono_declsec_get_demands
|
||||
mono_declsec_get_inheritdemands_class
|
||||
mono_declsec_get_inheritdemands_method
|
||||
mono_declsec_get_linkdemands
|
||||
mono_declsec_get_method_action
|
||||
mono_digest_get_public_token
|
||||
mono_disasm_code
|
||||
mono_disasm_code_one
|
||||
mono_dllmap_insert
|
||||
mono_domain_assembly_open
|
||||
mono_domain_create
|
||||
mono_domain_create_appdomain
|
||||
mono_domain_finalize
|
||||
mono_domain_foreach
|
||||
mono_domain_free
|
||||
mono_domain_from_appdomain
|
||||
mono_domain_get
|
||||
mono_domain_get_by_id
|
||||
mono_domain_get_id
|
||||
mono_domain_has_type_resolve
|
||||
mono_domain_is_unloading
|
||||
mono_domain_owns_vtable_slot
|
||||
mono_domain_set
|
||||
mono_domain_set_internal
|
||||
mono_domain_try_type_resolve
|
||||
mono_domain_try_unload
|
||||
mono_domain_unload
|
||||
mono_emit_native_call
|
||||
mono_environment_exitcode_get
|
||||
mono_environment_exitcode_set
|
||||
mono_error_cleanup
|
||||
mono_error_get_error_code
|
||||
mono_error_get_message
|
||||
mono_error_init
|
||||
mono_error_init_flags
|
||||
mono_error_ok
|
||||
mono_escape_uri_string
|
||||
mono_event_get_add_method
|
||||
mono_event_get_flags
|
||||
mono_event_get_name
|
||||
mono_event_get_object
|
||||
mono_event_get_parent
|
||||
mono_event_get_raise_method
|
||||
mono_event_get_remove_method
|
||||
mono_exception_from_name
|
||||
mono_exception_from_name_domain
|
||||
mono_exception_from_name_msg
|
||||
mono_exception_from_name_two_strings
|
||||
mono_exception_from_token
|
||||
mono_exception_from_token_two_strings
|
||||
mono_field_from_token
|
||||
mono_field_full_name
|
||||
mono_field_get_data
|
||||
mono_field_get_flags
|
||||
mono_field_get_name
|
||||
mono_field_get_object
|
||||
mono_field_get_offset
|
||||
mono_field_get_parent
|
||||
mono_field_get_type
|
||||
mono_field_get_value
|
||||
mono_field_get_value_object
|
||||
mono_field_set_value
|
||||
mono_field_static_get_value
|
||||
mono_field_static_set_value
|
||||
mono_file_map
|
||||
mono_file_map_close
|
||||
mono_file_map_fd
|
||||
mono_file_map_open
|
||||
mono_file_map_size
|
||||
mono_file_unmap
|
||||
mono_free
|
||||
mono_free_bstr
|
||||
mono_free_method
|
||||
mono_free_verify_list
|
||||
mono_gc_collect
|
||||
mono_gc_collection_count
|
||||
mono_gc_enable_events
|
||||
mono_gc_get_generation
|
||||
mono_gc_get_heap_size
|
||||
mono_gc_get_used_size
|
||||
mono_gchandle_free
|
||||
mono_gchandle_get_target
|
||||
mono_gchandle_new
|
||||
mono_gchandle_new_weakref
|
||||
mono_gc_invoke_finalizers
|
||||
mono_gc_is_finalizer_thread
|
||||
mono_gc_max_generation
|
||||
mono_gc_out_of_memory
|
||||
mono_gc_wbarrier_arrayref_copy
|
||||
mono_gc_wbarrier_generic_nostore
|
||||
mono_gc_wbarrier_generic_store
|
||||
mono_gc_wbarrier_generic_store_atomic
|
||||
mono_gc_wbarrier_object_copy
|
||||
mono_gc_wbarrier_set_arrayref
|
||||
mono_gc_wbarrier_set_field
|
||||
mono_gc_wbarrier_value_copy
|
||||
mono_get_array_class
|
||||
mono_get_boolean_class
|
||||
mono_get_byte_class
|
||||
mono_get_char_class
|
||||
mono_get_config_dir
|
||||
mono_get_corlib
|
||||
mono_get_dbnull_object
|
||||
mono_get_delegate_invoke
|
||||
mono_get_double_class
|
||||
mono_get_enum_class
|
||||
mono_get_exception_appdomain_unloaded
|
||||
mono_get_exception_argument
|
||||
mono_get_exception_argument_null
|
||||
mono_get_exception_argument_out_of_range
|
||||
mono_get_exception_arithmetic
|
||||
mono_get_exception_array_type_mismatch
|
||||
mono_get_exception_bad_image_format
|
||||
mono_get_exception_bad_image_format2
|
||||
mono_get_exception_cannot_unload_appdomain
|
||||
mono_get_exception_class
|
||||
mono_get_exception_divide_by_zero
|
||||
mono_get_exception_execution_engine
|
||||
mono_get_exception_field_access
|
||||
mono_get_exception_file_not_found
|
||||
mono_get_exception_file_not_found2
|
||||
mono_get_exception_index_out_of_range
|
||||
mono_get_exception_invalid_cast
|
||||
mono_get_exception_invalid_operation
|
||||
mono_get_exception_io
|
||||
mono_get_exception_method_access
|
||||
mono_get_exception_missing_field
|
||||
mono_get_exception_missing_method
|
||||
mono_get_exception_not_implemented
|
||||
mono_get_exception_not_supported
|
||||
mono_get_exception_null_reference
|
||||
mono_get_exception_out_of_memory
|
||||
mono_get_exception_overflow
|
||||
mono_get_exception_reflection_type_load
|
||||
mono_get_exception_security
|
||||
mono_get_exception_serialization
|
||||
mono_get_exception_stack_overflow
|
||||
mono_get_exception_synchronization_lock
|
||||
mono_get_exception_thread_abort
|
||||
mono_get_exception_thread_interrupted
|
||||
mono_get_exception_thread_state
|
||||
mono_get_exception_type_initialization
|
||||
mono_get_exception_type_load
|
||||
mono_get_int16_class
|
||||
mono_get_int32_class
|
||||
mono_get_int64_class
|
||||
mono_get_intptr_class
|
||||
mono_get_machine_config
|
||||
mono_get_method
|
||||
mono_get_method_full
|
||||
mono_get_object_class
|
||||
mono_get_root_domain
|
||||
mono_get_sbyte_class
|
||||
mono_get_single_class
|
||||
mono_get_string_class
|
||||
mono_get_thread_class
|
||||
mono_get_trampoline_func
|
||||
mono_get_uint16_class
|
||||
mono_get_uint32_class
|
||||
mono_get_uint64_class
|
||||
mono_get_uintptr_class
|
||||
mono_get_void_class
|
||||
mono_g_hash_table_destroy
|
||||
mono_g_hash_table_find
|
||||
mono_g_hash_table_foreach
|
||||
mono_g_hash_table_foreach_remove
|
||||
mono_g_hash_table_insert
|
||||
mono_g_hash_table_lookup
|
||||
mono_g_hash_table_lookup_extended
|
||||
mono_g_hash_table_new
|
||||
mono_g_hash_table_new_full
|
||||
mono_g_hash_table_new_type
|
||||
mono_g_hash_table_remove
|
||||
mono_g_hash_table_replace
|
||||
mono_g_hash_table_size
|
||||
mono_guid_to_string
|
||||
mono_hazard_pointer_get
|
||||
mono_image_addref
|
||||
mono_image_close
|
||||
mono_image_ensure_section
|
||||
mono_image_ensure_section_idx
|
||||
mono_image_fixup_vtable
|
||||
mono_image_get_assembly
|
||||
mono_image_get_entry_point
|
||||
mono_image_get_filename
|
||||
mono_image_get_guid
|
||||
mono_image_get_name
|
||||
mono_image_get_public_key
|
||||
mono_image_get_resource
|
||||
mono_image_get_strong_name
|
||||
mono_image_get_table_info
|
||||
mono_image_get_table_rows
|
||||
mono_image_has_authenticode_entry
|
||||
mono_image_is_dynamic
|
||||
mono_image_loaded
|
||||
mono_image_loaded_by_guid
|
||||
mono_image_loaded_by_guid_full
|
||||
mono_image_loaded_full
|
||||
mono_image_load_file_for_image
|
||||
mono_image_lookup_resource
|
||||
mono_image_open
|
||||
mono_image_open_from_data
|
||||
mono_image_open_from_data_full
|
||||
mono_image_open_from_data_with_name
|
||||
mono_image_open_full
|
||||
mono_image_rva_map
|
||||
mono_images_cleanup
|
||||
mono_image_strerror
|
||||
mono_image_strong_name_position
|
||||
mono_init
|
||||
mono_init_from_assembly
|
||||
mono_init_version
|
||||
mono_install_assembly_load_hook
|
||||
mono_install_assembly_postload_refonly_search_hook
|
||||
mono_install_assembly_postload_search_hook
|
||||
mono_install_assembly_preload_hook
|
||||
mono_install_assembly_refonly_preload_hook
|
||||
mono_install_assembly_refonly_search_hook
|
||||
mono_install_assembly_search_hook
|
||||
mono_install_runtime_cleanup
|
||||
mono_install_threadpool_item_hooks
|
||||
mono_install_threadpool_thread_hooks
|
||||
mono_inst_name
|
||||
mono_is_debugger_attached
|
||||
mono_jit_cleanup
|
||||
mono_jit_exec
|
||||
mono_jit_info_get_code_size
|
||||
mono_jit_info_get_code_start
|
||||
mono_jit_info_get_method
|
||||
mono_jit_info_table_find
|
||||
mono_jit_init
|
||||
mono_jit_init_version
|
||||
mono_jit_parse_options
|
||||
mono_jit_set_aot_only
|
||||
mono_jit_set_trace_options
|
||||
mono_ldstr
|
||||
mono_ldtoken
|
||||
mono_llvm_build_aligned_load
|
||||
mono_llvm_build_alloca
|
||||
mono_llvm_build_load
|
||||
mono_llvm_create_ee
|
||||
mono_llvm_dispose_ee
|
||||
mono_llvm_dump_value
|
||||
mono_llvm_optimize_method
|
||||
mono_llvm_replace_uses_of
|
||||
mono_load_remote_field
|
||||
mono_load_remote_field_new
|
||||
mono_local_deadce
|
||||
mono_locks_dump
|
||||
mono_lookup_internal_call
|
||||
mono_lookup_pinvoke_call
|
||||
mono_main
|
||||
mono_marshal_string_to_utf16
|
||||
mono_md5_final
|
||||
mono_md5_get_digest
|
||||
mono_md5_get_digest_from_file
|
||||
mono_md5_init
|
||||
mono_md5_update
|
||||
mono_mempool_alloc
|
||||
mono_mempool_alloc0
|
||||
mono_mempool_contains_addr
|
||||
mono_mempool_destroy
|
||||
mono_mempool_empty
|
||||
mono_mempool_get_allocated
|
||||
mono_mempool_invalidate
|
||||
mono_mempool_new
|
||||
mono_mempool_new_size
|
||||
mono_mempool_stats
|
||||
mono_mempool_strdup
|
||||
mono_metadata_blob_heap
|
||||
mono_metadata_cleanup
|
||||
mono_metadata_compute_size
|
||||
mono_metadata_custom_attrs_from_index
|
||||
mono_metadata_declsec_from_index
|
||||
mono_metadata_decode_blob_size
|
||||
mono_metadata_decode_row
|
||||
mono_metadata_decode_row_col
|
||||
mono_metadata_decode_signed_value
|
||||
mono_metadata_decode_table_row
|
||||
mono_metadata_decode_table_row_col
|
||||
mono_metadata_decode_value
|
||||
mono_metadata_encode_value
|
||||
mono_metadata_events_from_typedef
|
||||
mono_metadata_field_info
|
||||
mono_metadata_field_info_with_mempool
|
||||
mono_metadata_free_array
|
||||
mono_metadata_free_inflated_signature
|
||||
mono_metadata_free_marshal_spec
|
||||
mono_metadata_free_method_signature
|
||||
mono_metadata_free_mh
|
||||
mono_metadata_free_type
|
||||
mono_metadata_generic_class_is_valuetype
|
||||
mono_metadata_get_constant_index
|
||||
mono_metadata_get_inflated_signature
|
||||
mono_metadata_get_marshal_info
|
||||
mono_metadata_guid_heap
|
||||
mono_metadata_implmap_from_method
|
||||
mono_metadata_interfaces_from_typedef
|
||||
mono_metadata_load_generic_params
|
||||
mono_metadata_locate
|
||||
mono_metadata_locate_token
|
||||
mono_metadata_methods_from_event
|
||||
mono_metadata_methods_from_property
|
||||
mono_metadata_nested_in_typedef
|
||||
mono_metadata_nesting_typedef
|
||||
mono_metadata_packing_from_typedef
|
||||
mono_metadata_parse_array
|
||||
mono_metadata_parse_custom_mod
|
||||
mono_metadata_parse_field_type
|
||||
mono_metadata_parse_marshal_spec
|
||||
mono_metadata_parse_method_signature
|
||||
mono_metadata_parse_method_signature_full
|
||||
mono_metadata_parse_mh
|
||||
mono_metadata_parse_mh_full
|
||||
mono_metadata_parse_param
|
||||
mono_metadata_parse_signature
|
||||
mono_metadata_parse_type
|
||||
mono_metadata_parse_typedef_or_ref
|
||||
mono_metadata_parse_type_full
|
||||
mono_metadata_properties_from_typedef
|
||||
mono_metadata_signature_alloc
|
||||
mono_metadata_signature_dup
|
||||
mono_metadata_signature_equal
|
||||
mono_metadata_string_heap
|
||||
mono_metadata_token_from_dor
|
||||
mono_metadata_translate_token_index
|
||||
mono_metadata_typedef_from_field
|
||||
mono_metadata_typedef_from_method
|
||||
mono_metadata_type_equal
|
||||
mono_metadata_type_hash
|
||||
mono_metadata_user_string
|
||||
mono_method_body_get_object
|
||||
mono_method_can_access_field
|
||||
mono_method_can_access_method
|
||||
mono_method_desc_free
|
||||
mono_method_desc_from_method
|
||||
mono_method_desc_full_match
|
||||
mono_method_desc_match
|
||||
mono_method_desc_new
|
||||
mono_method_desc_search_in_class
|
||||
mono_method_desc_search_in_image
|
||||
mono_method_full_name
|
||||
mono_method_get_class
|
||||
mono_method_get_flags
|
||||
mono_method_get_generic_container
|
||||
mono_method_get_header
|
||||
mono_method_get_index
|
||||
mono_method_get_last_managed
|
||||
mono_method_get_marshal_info
|
||||
mono_method_get_name
|
||||
mono_method_get_object
|
||||
mono_method_get_param_names
|
||||
mono_method_get_param_token
|
||||
mono_method_get_signature
|
||||
mono_method_get_signature_full
|
||||
mono_method_get_token
|
||||
mono_method_get_unmanaged_thunk
|
||||
mono_method_has_marshal_info
|
||||
mono_method_header_get_clauses
|
||||
mono_method_header_get_code
|
||||
mono_method_header_get_locals
|
||||
mono_method_header_get_num_clauses
|
||||
mono_method_signature
|
||||
mono_method_verify
|
||||
mono_mlist_alloc
|
||||
mono_mlist_append
|
||||
mono_mlist_get_data
|
||||
mono_mlist_last
|
||||
mono_mlist_length
|
||||
mono_mlist_next
|
||||
mono_mlist_prepend
|
||||
mono_mlist_remove_item
|
||||
mono_mlist_set_data
|
||||
mono_mlist_set_next
|
||||
mono_module_file_get_object
|
||||
mono_module_get_object
|
||||
mono_monitor_enter
|
||||
mono_monitor_exit
|
||||
mono_monitor_try_enter
|
||||
mono_mprotect
|
||||
mono_object_castclass_mbyref
|
||||
mono_object_clone
|
||||
mono_object_describe
|
||||
mono_object_describe_fields
|
||||
mono_object_get_class
|
||||
mono_object_get_domain
|
||||
mono_object_get_size
|
||||
mono_object_get_virtual_method
|
||||
mono_object_is_alive
|
||||
mono_object_isinst
|
||||
mono_object_isinst_mbyref
|
||||
mono_object_new
|
||||
mono_object_new_alloc_specific
|
||||
mono_object_new_fast
|
||||
mono_object_new_from_token
|
||||
mono_object_new_specific
|
||||
mono_object_unbox
|
||||
mono_opcode_name
|
||||
mono_opcode_value
|
||||
mono_op_to_op_imm_noemul
|
||||
mono_pagesize
|
||||
mono_param_get_objects
|
||||
mono_parse_default_optimizations
|
||||
mono_path_canonicalize
|
||||
mono_path_resolve_symlinks
|
||||
mono_pe_file_open
|
||||
mono_perfcounters_init
|
||||
mono_personality
|
||||
mono_pmip
|
||||
mono_print_method_from_ip
|
||||
mono_print_thread_dump
|
||||
mono_print_thread_dump_from_ctx
|
||||
mono_print_unhandled_exception
|
||||
mono_profiler_coverage_get
|
||||
mono_profiler_get_events
|
||||
mono_profiler_install
|
||||
mono_profiler_install_allocation
|
||||
mono_profiler_install_appdomain
|
||||
mono_profiler_install_assembly
|
||||
mono_profiler_install_class
|
||||
mono_profiler_install_code_buffer_new
|
||||
mono_profiler_install_code_chunk_destroy
|
||||
mono_profiler_install_code_chunk_new
|
||||
mono_profiler_install_coverage_filter
|
||||
mono_profiler_install_enter_leave
|
||||
mono_profiler_install_exception
|
||||
mono_profiler_install_gc
|
||||
mono_profiler_install_gc_moves
|
||||
mono_profiler_install_iomap
|
||||
mono_profiler_install_jit_compile
|
||||
mono_profiler_install_jit_end
|
||||
mono_profiler_install_method_free
|
||||
mono_profiler_install_method_invoke
|
||||
mono_profiler_install_module
|
||||
mono_profiler_install_monitor
|
||||
mono_profiler_install_runtime_initialized
|
||||
mono_profiler_install_statistical
|
||||
mono_profiler_install_statistical_call_chain
|
||||
mono_profiler_install_thread
|
||||
mono_profiler_install_transition
|
||||
mono_profiler_load
|
||||
mono_profiler_set_events
|
||||
mono_property_get_flags
|
||||
mono_property_get_get_method
|
||||
mono_property_get_name
|
||||
mono_property_get_object
|
||||
mono_property_get_parent
|
||||
mono_property_get_set_method
|
||||
mono_property_get_value
|
||||
mono_property_hash_destroy
|
||||
mono_property_hash_insert
|
||||
mono_property_hash_lookup
|
||||
mono_property_hash_new
|
||||
mono_property_hash_remove_object
|
||||
mono_property_set_value
|
||||
mono_ptr_class_get
|
||||
mono_raise_exception
|
||||
mono_reflection_free_type_info
|
||||
mono_reflection_get_custom_attrs
|
||||
mono_reflection_get_custom_attrs_blob
|
||||
mono_reflection_get_custom_attrs_by_type
|
||||
mono_reflection_get_custom_attrs_data
|
||||
mono_reflection_get_custom_attrs_info
|
||||
mono_reflection_get_token
|
||||
mono_reflection_get_type
|
||||
mono_reflection_parse_type
|
||||
mono_reflection_type_from_name
|
||||
mono_register_bundled_assemblies
|
||||
mono_register_machine_config
|
||||
mono_replace_ins
|
||||
mono_runtime_class_init
|
||||
mono_runtime_cleanup
|
||||
mono_runtime_delegate_invoke
|
||||
mono_runtime_exec_main
|
||||
mono_runtime_exec_managed_code
|
||||
mono_runtime_get_main_args
|
||||
mono_runtime_init
|
||||
mono_runtime_invoke
|
||||
mono_runtime_invoke_array
|
||||
mono_runtime_is_shutting_down
|
||||
mono_runtime_object_init
|
||||
mono_runtime_quit
|
||||
mono_runtime_run_main
|
||||
mono_security_core_clr_require_elevated_permissions
|
||||
mono_security_enable_core_clr
|
||||
mono_security_set_core_clr_platform_callback
|
||||
mono_sem_post
|
||||
mono_sem_timedwait
|
||||
mono_sem_wait
|
||||
mono_set_break_policy
|
||||
mono_set_defaults
|
||||
mono_set_dirs
|
||||
mono_set_is_debugger_attached
|
||||
mono_set_signal_chaining
|
||||
mono_sha1_final
|
||||
mono_sha1_get_digest
|
||||
mono_sha1_get_digest_from_file
|
||||
mono_sha1_init
|
||||
mono_sha1_update
|
||||
mono_signature_explicit_this
|
||||
mono_signature_get_call_conv
|
||||
mono_signature_get_desc
|
||||
mono_signature_get_param_count
|
||||
mono_signature_get_params
|
||||
mono_signature_get_return_type
|
||||
mono_signature_hash
|
||||
mono_signature_is_instance
|
||||
mono_signature_vararg_start
|
||||
mono_signbit_double
|
||||
mono_signbit_float
|
||||
mono_stack_walk
|
||||
mono_stack_walk_no_il
|
||||
mono_store_remote_field
|
||||
mono_store_remote_field_new
|
||||
mono_string_chars
|
||||
mono_string_equal
|
||||
mono_string_from_bstr
|
||||
mono_string_from_utf16
|
||||
mono_string_hash
|
||||
mono_stringify_assembly_name
|
||||
mono_string_intern
|
||||
mono_string_is_interned
|
||||
mono_string_length
|
||||
mono_string_new
|
||||
mono_string_new_len
|
||||
mono_string_new_size
|
||||
mono_string_new_utf16
|
||||
mono_string_new_wrapper
|
||||
mono_string_to_utf16
|
||||
mono_string_to_utf8
|
||||
mono_table_info_get_rows
|
||||
mono_thread_attach
|
||||
mono_thread_cleanup
|
||||
mono_thread_create
|
||||
mono_thread_current
|
||||
mono_thread_detach
|
||||
mono_thread_exit
|
||||
mono_thread_get_main
|
||||
mono_thread_get_undeniable_exception
|
||||
mono_thread_hazardous_free_or_queue
|
||||
mono_thread_hazardous_try_free_all
|
||||
mono_thread_manage
|
||||
mono_thread_new_init
|
||||
mono_thread_set_main
|
||||
mono_thread_set_manage_callback
|
||||
mono_threads_get_default_stacksize
|
||||
mono_threads_install_cleanup
|
||||
mono_threads_request_thread_dump
|
||||
mono_threads_set_default_stacksize
|
||||
mono_thread_stop
|
||||
mono_trace_set_level_string
|
||||
mono_trace_set_mask_string
|
||||
mono_type_create_from_typespec
|
||||
mono_type_full_name
|
||||
mono_type_generic_inst_is_valuetype
|
||||
mono_type_get_array_type
|
||||
mono_type_get_class
|
||||
mono_type_get_desc
|
||||
mono_type_get_modifiers
|
||||
mono_type_get_name
|
||||
mono_type_get_object
|
||||
mono_type_get_ptr_type
|
||||
mono_type_get_signature
|
||||
mono_type_get_type
|
||||
mono_type_get_underlying_type
|
||||
mono_type_is_byref
|
||||
mono_type_is_pointer
|
||||
mono_type_is_reference
|
||||
mono_type_is_struct
|
||||
mono_type_is_valid_enum_basetype
|
||||
mono_type_is_void
|
||||
mono_type_size
|
||||
mono_type_stack_size
|
||||
mono_type_to_unmanaged
|
||||
mono_unhandled_exception
|
||||
mono_unicode_from_external
|
||||
mono_unicode_to_external
|
||||
mono_upgrade_remote_class_wrapper
|
||||
mono_utf8_from_external
|
||||
mono_utf8_validate_and_len
|
||||
mono_utf8_validate_and_len_with_bounds
|
||||
mono_valloc
|
||||
mono_value_box
|
||||
mono_value_copy
|
||||
mono_value_copy_array
|
||||
mono_value_describe_fields
|
||||
mono_verify_corlib
|
||||
mono_vfree
|
||||
mono_vtable_get_static_field_data
|
||||
mono_walk_stack
|
||||
mono_win32_compat_CopyMemory
|
||||
mono_win32_compat_FillMemory
|
||||
mono_win32_compat_MoveMemory
|
||||
mono_win32_compat_ZeroMemory
|
||||
_ZN20MonoJITMemoryManager11AllocateGOTEv
|
||||
_ZN20MonoJITMemoryManager12allocateStubEPKN4llvm11GlobalValueEjj
|
||||
_ZN20MonoJITMemoryManager13allocateSpaceEij
|
||||
_ZN20MonoJITMemoryManager13SetDlsymTableEPv
|
||||
_ZN20MonoJITMemoryManager14allocateGlobalEjj
|
||||
_ZN20MonoJITMemoryManager15endFunctionBodyEPKN4llvm8FunctionEPhS4_
|
||||
_ZN20MonoJITMemoryManager17endExceptionTableEPKN4llvm8FunctionEPhS4_S4_
|
||||
_ZN20MonoJITMemoryManager17setMemoryWritableEv
|
||||
_ZN20MonoJITMemoryManager17startFunctionBodyEPKN4llvm8FunctionERj
|
||||
_ZN20MonoJITMemoryManager19setMemoryExecutableEv
|
||||
_ZN20MonoJITMemoryManager19startExceptionTableEPKN4llvm8FunctionERj
|
||||
_ZN20MonoJITMemoryManager24deallocateMemForFunctionEPKN4llvm8FunctionE
|
||||
_ZN20MonoJITMemoryManagerC1Ev
|
||||
_ZN20MonoJITMemoryManagerC2Ev
|
||||
_ZN20MonoJITMemoryManagerD0Ev
|
||||
_ZN20MonoJITMemoryManagerD1Ev
|
||||
_ZN20MonoJITMemoryManagerD2Ev
|
||||
CloseHandle
|
||||
closesocket
|
||||
CopyFile
|
||||
CreateDirectory
|
||||
CreateEvent
|
||||
CreateFile
|
||||
CreateMutex
|
||||
CreatePipe
|
||||
CreateProcess
|
||||
CreateProcessWithLogonW
|
||||
CreateSemaphore
|
||||
CreateThread
|
||||
DeleteCriticalSection
|
||||
DeleteFile
|
||||
DuplicateHandle
|
||||
EnumProcesses
|
||||
EnumProcessModules
|
||||
errno_to_WSA
|
||||
ExitThread
|
||||
FileTimeToSystemTime
|
||||
FindClose
|
||||
FindFirstFile
|
||||
FindNextFile
|
||||
FlushFileBuffers
|
||||
FormatMessage
|
||||
GetCurrentDirectory
|
||||
GetCurrentProcess
|
||||
GetCurrentProcessId
|
||||
GetCurrentThread
|
||||
GetCurrentThreadId
|
||||
GetDiskFreeSpaceEx
|
||||
GetDriveType
|
||||
GetExitCodeProcess
|
||||
GetExitCodeThread
|
||||
GetFileAttributes
|
||||
GetFileAttributesEx
|
||||
GetFileSize
|
||||
GetFileTime
|
||||
GetFileType
|
||||
GetFileVersionInfo
|
||||
GetFileVersionInfoSize
|
||||
GetLastError
|
||||
GetLogicalDriveStrings
|
||||
GetModuleBaseName
|
||||
GetModuleFileNameEx
|
||||
GetModuleInformation
|
||||
GetPriorityClass
|
||||
GetProcessId
|
||||
GetProcessTimes
|
||||
GetProcessWorkingSetSize
|
||||
GetStdHandle
|
||||
GetSystemInfo
|
||||
GetTempPath
|
||||
GetThreadContext
|
||||
GetTickCount
|
||||
ImpersonateLoggedOnUser
|
||||
InitializeCriticalSection
|
||||
InitializeCriticalSectionAndSpinCount
|
||||
ioctlsocket
|
||||
LockFile
|
||||
mono_once
|
||||
mono_pthread_key_for_tls
|
||||
MoveFile
|
||||
OpenEvent
|
||||
OpenMutex
|
||||
OpenProcess
|
||||
OpenSemaphore
|
||||
OpenThread
|
||||
PulseEvent
|
||||
QueryPerformanceCounter
|
||||
QueryPerformanceFrequency
|
||||
QueueUserAPC
|
||||
ReadFile
|
||||
ReleaseMutex
|
||||
ReleaseSemaphore
|
||||
RemoveDirectory
|
||||
ReplaceFile
|
||||
ResetEvent
|
||||
ResumeThread
|
||||
RevertToSelf
|
||||
SetCriticalSectionSpinCount
|
||||
SetCurrentDirectory
|
||||
SetEndOfFile
|
||||
SetEvent
|
||||
SetFileAttributes
|
||||
SetFilePointer
|
||||
SetFileTime
|
||||
SetLastError
|
||||
SetPriorityClass
|
||||
SetProcessWorkingSetSize
|
||||
ShellExecuteEx
|
||||
SignalObjectAndWait
|
||||
Sleep
|
||||
SleepEx
|
||||
SuspendThread
|
||||
TerminateProcess
|
||||
TlsAlloc
|
||||
TlsFree
|
||||
TlsGetValue
|
||||
TlsSetValue
|
||||
TransmitFile
|
||||
TryEnterCriticalSection
|
||||
UnlockFile
|
||||
VerLanguageName
|
||||
VerQueryValue
|
||||
WaitForInputIdle
|
||||
WaitForMultipleObjects
|
||||
WaitForMultipleObjectsEx
|
||||
WaitForSingleObject
|
||||
WaitForSingleObjectEx
|
||||
wapi_clear_interruption
|
||||
wapi_current_thread_desc
|
||||
wapi_interrupt_thread
|
||||
wapi_self_interrupt
|
||||
wapi_thread_clear_wait_handle
|
||||
wapi_thread_set_wait_handle
|
||||
WriteFile
|
||||
WSACleanup
|
||||
WSAGetLastError
|
||||
WSAIoctl
|
||||
WSARecv
|
||||
WSASend
|
||||
WSASetLastError
|
||||
WSAStartup
|
||||
+1023
File diff suppressed because it is too large.
Load diff
@@ -71,3 +71,40 @@ unwinding code.
|
||||
|
||||
catch handler: catch hanlders are always called from the stack unwinding
|
||||
code. The exception object is passed in a local variable (cfg->exvar).
|
||||
|
||||
gcc support for Exceptions
|
||||
==========================
|
||||
|
||||
gcc supports exceptions in files compiled with the -fexception option. gcc
|
||||
generates DWARF exceptions tables in that case, so it is possible to unwind the
|
||||
stack. The method to read those exception tables is contained in libgcc.a, and
|
||||
in newer versions of glibc (glibc 2.2.5 for example), and it is called
|
||||
__frame_state_for(). Another usable glibc function is backtrace_symbols() which
|
||||
returns the function name corresponding to a code address.
|
||||
|
||||
We dynamically check if those features are available using g_module_symbol(),
|
||||
and we use them only when available. If not available we use the LMF as
|
||||
fallback.
|
||||
|
||||
Using gcc exception information prevents us from saving the LMF at each native
|
||||
call, so this is a way to speed up native calls. This is especially valuable
|
||||
for internal calls, because we can make sure that all internal calls are
|
||||
compiled with -fexceptions (we compile the whole mono runtime with that
|
||||
option).
|
||||
|
||||
All native function are able to call function without exception tables, and so
|
||||
we are unable to restore all caller saved registers if an exception is raised
|
||||
in such function. Well, its possible if the previous function already saves all
|
||||
registers. So we only omit the the LMF if a function has an exception table
|
||||
able to restore all caller saved registers.
|
||||
|
||||
One problem is that gcc almost never saves all caller saved registers, because
|
||||
it is just unnecessary in normal situations. But there is a trick forcing gcc
|
||||
to save all register, we just need to call __builtin_unwind_init() at the
|
||||
beginning of a function. That way gcc generates code to save all caller saved
|
||||
register on the stack.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
+72
-98
@@ -7,10 +7,6 @@ if ($ARGV[0] eq "-h"){
|
||||
shift @ARGV;
|
||||
shift @ARGV;
|
||||
}
|
||||
open (FILE, "$dir/api-style.css" || die "Did not find $dir/api-style.css");
|
||||
while (<FILE>){
|
||||
$css = $css . $_;
|
||||
}
|
||||
|
||||
if ($ARGV[0] eq "-t"){
|
||||
$dir = $ARGV[1];
|
||||
@@ -53,114 +49,109 @@ if ($html){
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<head>
|
||||
<title>$name</title>
|
||||
<style type="text/css">
|
||||
$css
|
||||
<title>$name</title>
|
||||
<style type="text/css">
|
||||
h3 {
|
||||
font-size: 18px;
|
||||
padding-bottom: 4pt;
|
||||
border-bottom: 2px solid #dddddd;
|
||||
}
|
||||
|
||||
.api {
|
||||
border: 1px solid;
|
||||
padding: 10pt;
|
||||
margin: 10pt;
|
||||
}
|
||||
|
||||
.api-entry {
|
||||
border-bottom: none;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.prototype {
|
||||
border: 1px solid;
|
||||
background-color: #f2f2f2;
|
||||
padding: 5pt;
|
||||
margin-top: 5pt;
|
||||
margin-bottom: 5pt;
|
||||
}
|
||||
|
||||
.header {
|
||||
border: 1px solid;
|
||||
padding: 0 0 5pt 5pt;
|
||||
margin: 10pt;
|
||||
white-space: pre;
|
||||
font-family: monospace;
|
||||
}
|
||||
|
||||
.code {
|
||||
border: 1px solid;
|
||||
padding: 0 0 5pt 5pt;
|
||||
margin: 10pt;
|
||||
white-space: pre;
|
||||
font-family: monospace;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="mapi-docs">
|
||||
EOF
|
||||
@a = split (/\n/, $files_content[$f]);
|
||||
$strikeextra = "";
|
||||
$api_shown = 0;
|
||||
|
||||
for ($ai = 0; $ai < $#a; $ai++){
|
||||
$line = $a[$ai];
|
||||
|
||||
($api,$caption) = $line =~ /<h4><a name=\"api:(\w+)\">(\w+)<\/a><\/h4>/;
|
||||
if ($api ne ""){
|
||||
if ($api_shown == 1){
|
||||
print OUT "</div> <!-- class=mapi -->\n\n";
|
||||
if ($deprecated{$api}){
|
||||
$strike = "mapi-strike";
|
||||
$strikeextra = "</div><br><div class='mapi-deprecated'><b>Deprecated:</b> " . $deprecated{$api};
|
||||
} else {
|
||||
$strike = "";
|
||||
$strikeextra = "";
|
||||
}
|
||||
print OUT "</div>";
|
||||
}
|
||||
$api_shown = 1;
|
||||
$proto = $prototype{$api};
|
||||
if ($proto eq ""){
|
||||
$proto = "$api";
|
||||
$proto = "Prototype: $api";
|
||||
}
|
||||
|
||||
print OUT<<EOF;
|
||||
<a name="api:$api"></a>
|
||||
<div class="mapi">
|
||||
<div class="mapi-entry $strike"><code>$api$strikeextra</code></div>
|
||||
<div class="mapi-height-container">
|
||||
<div class="mapi-ptr-container"></div>
|
||||
<div class="mapi-description">
|
||||
<div class="mapi-ptr"></div>
|
||||
print OUT<<EOF;
|
||||
<a name="api:$api"></a>
|
||||
<div class="api">
|
||||
<div class="api-entry">$api</div>
|
||||
|
||||
<div class="mapi-declaration mapi-section">Syntax</div>
|
||||
<div class="mapi-prototype">$proto</div>
|
||||
<p>
|
||||
<div class="prototype">$proto</div>
|
||||
<p>
|
||||
EOF
|
||||
$ppars = $arguments{$api};
|
||||
if ($ppars ne "" && (!($ppars =~ /^[ \t]+$/))){
|
||||
print OUT " <div class=\"mapi-section\">Parameters</div>\n";
|
||||
print OUT " <table class=\"mapi-parameters\"><tbody>".${arguments{$api}}."</tbody></table>";
|
||||
}
|
||||
|
||||
&opt_print ("Return value", $returns{$api}, 0);
|
||||
&opt_print ("Description", $bodies{$api}, 0);
|
||||
print OUT " </div><!--mapi-description-->\n </div><!--height container-->\n";
|
||||
&opt_print ("Parameters", $arguments{$api}, 1);
|
||||
&opt_print ("Returns", $returns{$api}, 1);
|
||||
&opt_print ("Remarks", $bodies{$api}, 0);
|
||||
print OUT "\n";
|
||||
} else {
|
||||
if ($line =~ /@API_IDX@/){
|
||||
$apis_toc = &create_toc ($apis[$f]);
|
||||
$line =~ s/\@API_IDX\@/$apis_toc/;
|
||||
}
|
||||
if ($line =~ /^<h4/){
|
||||
print OUT "</div>\n";
|
||||
if ($line =~ /^<h/){
|
||||
print OUT "</div>";
|
||||
$api_shown = 0;
|
||||
}
|
||||
if ($line =~ /`/){
|
||||
}
|
||||
|
||||
print OUT "$line\n";
|
||||
}
|
||||
}
|
||||
print OUT<<EOF;
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
EOF
|
||||
close OUT;
|
||||
system ("$ENV{runtimedir}/mono-wrapper convert.exe $dir/html/$name $dir/html/x-$name");
|
||||
|
||||
|
||||
# clean up the mess that AgilityPack does, it CDATAs our CSS
|
||||
open HACK, "$dir/html/x-$name" || die "Could not open $dir/html/x-$name";
|
||||
open HACKOUT, ">$dir/deploy/$name" || die "Could not open output";
|
||||
|
||||
$line = 0;
|
||||
$doprint = 0;
|
||||
while (<HACK>){
|
||||
print HACKOUT $last if ($doprint);
|
||||
$line++;
|
||||
s/^\/\/<!\[CDATA\[//;
|
||||
s/^\/\/\]\]>\/\///;
|
||||
|
||||
# Remove the junk <span> wrapper generated by AgilityPack
|
||||
if ($line==1){
|
||||
s/<span>//;
|
||||
}
|
||||
if (/<style type/){
|
||||
# Replace the CSS in the XHTML output with the original CSS
|
||||
print HACKOUT $_;
|
||||
print HACKOUT $css;
|
||||
while (<HACK>){
|
||||
last if (/<\/style>/);
|
||||
}
|
||||
}
|
||||
$last = $_;
|
||||
$doprint = 1;
|
||||
print HACKOUT $_;
|
||||
}
|
||||
if (!($last =~ /span/)){
|
||||
print HACKOUT $last;
|
||||
}
|
||||
|
||||
#system ("cp.exe $dir/html/$name $dir/deploy/$name");
|
||||
}
|
||||
}
|
||||
@@ -177,29 +168,17 @@ sub process_doc {
|
||||
$returns = "";
|
||||
$body = "";
|
||||
$functions[$fn++] = $func;
|
||||
$deprecated = 0;
|
||||
|
||||
# Process arguments
|
||||
while (<>){
|
||||
s/NULL/<code>NULL<\/code>/g;
|
||||
s/TRUE/<code>TRUE<\/code>/g;
|
||||
s/FALSE/<code>FALSE<\/code>/g;
|
||||
if (/^ \*\*?\//){
|
||||
$body =~ s/@(\w+)/<i>\1<\/i>/g;
|
||||
$returns =~ s/@(\w+)/<i>\1<\/i>/g;
|
||||
if (/^ \*\*?\//){
|
||||
$body =~ s/[@#](\w+)/<i>\1<\/i>/g;
|
||||
$returns =~ s/[@#](\w+)/<i>\1<\/i>/g;
|
||||
|
||||
$args =~ s/@(\w+)/<i>\1<\/i>/g;
|
||||
|
||||
$body =~ s/#(\w+)/<code>\1<\/code>/g;
|
||||
$returns =~ s/#(\w+)/<code>\1<\/code>/g;
|
||||
$args =~ s/#(\w+)/<code>\1<\/code>/g;
|
||||
|
||||
$returns =~ s/\`([:.\w\*]+)\`/<code>\1<\/code>/g;
|
||||
$args =~ s/\`([:.\w\*]+)\`/<code>\1<\/code>/g;
|
||||
$body =~ s/\`([:.\w\*]+)\`/<code>\1<\/code>/g;
|
||||
|
||||
$body =~ s/\n/ /;
|
||||
$bodies{$func} = $body;
|
||||
$arguments{$func} = $args;
|
||||
$deprecated{$func} = $deprecated;
|
||||
$returns{$func} = $returns;
|
||||
$proto = "";
|
||||
while (<>){
|
||||
@@ -216,20 +195,14 @@ sub process_doc {
|
||||
}
|
||||
chop;
|
||||
s/^\ \*//;
|
||||
$_ = "<p>" if (/^\s*$/);
|
||||
$_ = "\n<p>" if (/^\s+$/);
|
||||
|
||||
if ($inbody == 0){
|
||||
if (/\s*(\w+):(.*)/){
|
||||
if ($1 eq "deprecated"){
|
||||
$deprecated = $2;
|
||||
} else {
|
||||
#$args .= "<dt><i>$1:</i></dt><dd>$2</dd>";
|
||||
$args .= "<tr><td><i>$1</i><td>$2</td></td></tr>";
|
||||
}
|
||||
$args .= "<dt><i>$1:</i></dt><dd>$2</dd>";
|
||||
} else {
|
||||
|
||||
$body = "\t$_\n";
|
||||
|
||||
$inbody = 1;
|
||||
}
|
||||
} elsif ($inbody == 1) {
|
||||
@@ -273,9 +246,6 @@ sub create_toc {
|
||||
chop;
|
||||
$p = $prototype{$line};
|
||||
($ret, $xname, $args) = $p =~ /(.*)\n(\w+)[ \t](.*)/;
|
||||
if ($xname eq ""){
|
||||
$xname = $line;
|
||||
}
|
||||
|
||||
$rspace = " " x ($type_size - length ($ret));
|
||||
$nspace = " " x ($name_size - length ($xname));
|
||||
@@ -319,7 +289,11 @@ sub opt_print {
|
||||
my ($caption, $opttext, $quote) = @_;
|
||||
|
||||
if ($opttext ne "" && (!($opttext =~ /^[ \t]+$/))){
|
||||
print OUT " <div class=\"mapi-section\">$caption</div>\n";
|
||||
print OUT " <div>$opttext</div>\n";
|
||||
print OUT "<b>$caption</b>\n";
|
||||
if ($quote == 1){
|
||||
print OUT "<blockquote>$opttext</blockquote>\n";
|
||||
} else {
|
||||
print OUT "<p>$opttext\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,208 @@
|
||||
|
||||
* Proposal for the local register allocator
|
||||
|
||||
The local register allocator deals with allocating registers
|
||||
for temporaries inside a single basic block, while the global
|
||||
register allocator is concerned with method-wide allocation of
|
||||
variables.
|
||||
The global register allocator uses callee-saved register for it's
|
||||
purpouse so that there is no need to save and restore these registers
|
||||
at call sites.
|
||||
|
||||
There are a number of issues the local allocator needs to deal with:
|
||||
*) some instructions expect operands in specific registers (for example
|
||||
the shl instruction on x86, or the call instruction with thiscall
|
||||
convention, or the equivalent call instructions on other architectures,
|
||||
such as the need to put output registers in %oX on sparc)
|
||||
*) some instructions deliver results only in specific registers (for example
|
||||
the div instruction on x86, or the call instructionson on almost all
|
||||
the architectures).
|
||||
*) it needs to know what registers may be clobbered by an instruction
|
||||
(such as in a method call)
|
||||
*) it should avoid excessive reloads or stores to improve performance
|
||||
|
||||
While which specific instructions have limitations is architecture-dependent,
|
||||
the problem shold be solved in an arch-independent way to reduce code duplication.
|
||||
The register allocator will be 'driven' by the arch-dependent code, but it's
|
||||
implementation should be arch-independent.
|
||||
|
||||
To improve the current local register allocator, we need to
|
||||
keep more state in it than the current setup that only keeps busy/free info.
|
||||
|
||||
Possible state information is:
|
||||
|
||||
free: the resgister is free to use and it doesn't contain useful info
|
||||
freeable: the register contains data loaded from a local (there is
|
||||
also info about _which_ local it contains) as a result from previous
|
||||
instructions (like, there was a store from the register to the local)
|
||||
moveable: it contains live data that is needed in a following instruction, but
|
||||
the contents may be moved to a different register
|
||||
busy: the register contains live data and it is placed there because
|
||||
the following instructions need it exactly in that register
|
||||
allocated: the register is used by the global allocator
|
||||
|
||||
The local register allocator will have the following interfaces:
|
||||
|
||||
int get_register ();
|
||||
Searches for a register in the free state. If it doesn't find it,
|
||||
searches for a freeable register. Sets the status to moveable.
|
||||
Looking for a 'free' register before a freeable one should allow for
|
||||
removing a few redundant loads (though I'm still unsure if such
|
||||
things should be delegated entirely to the peephole pass).
|
||||
|
||||
int get_register_force (int reg);
|
||||
Returns 'reg' if it is free or freeable. If it is moveable, it moves it
|
||||
to another free or freeable register.
|
||||
Sets the status of 'reg' to busy.
|
||||
|
||||
void set_register_freeable (int reg);
|
||||
Sets the status of 'reg' to freeable.
|
||||
|
||||
void set_register_free (int reg);
|
||||
Sets the status of 'reg' to free.
|
||||
|
||||
void will_clobber (int reg);
|
||||
Spills the register to the stack. Sets the status to freeable.
|
||||
After the clobbering has occurred, set the status to free.
|
||||
|
||||
void register_unspill (int reg);
|
||||
Un-spills register reg and sets the status to moveable.
|
||||
|
||||
FIXME: how is the 'local' information represented? Maybe a MonoInst* pointer.
|
||||
|
||||
Note: the register allocator will insert instructions in the basic block
|
||||
during it's operation.
|
||||
|
||||
* Examples
|
||||
|
||||
Given the tree (on x86 the right argument to shl needs to be in ecx):
|
||||
|
||||
store (local1, shl (local1, call (some_arg)))
|
||||
|
||||
At the start of the basic block, the registers are set to the free state.
|
||||
The sequence of instructions may be:
|
||||
instruction register status -> [%eax %ecx %edx]
|
||||
start free free free
|
||||
eax = load local1 mov free free
|
||||
/* call clobbers eax, ecx, edx */
|
||||
spill eax free free free
|
||||
call mov free free
|
||||
/* now eax contains the right operand of the shl */
|
||||
mov %eax -> %ecx free busy free
|
||||
un-spill mov busy free
|
||||
shl %cl, %eax mov free free
|
||||
|
||||
The resulting x86 code is:
|
||||
mov $fffc(%ebp), %eax
|
||||
mov %eax, $fff0(%ebp)
|
||||
push some_arg
|
||||
call func
|
||||
mov %eax, %ecx
|
||||
mov $fff0(%ebp), %eax
|
||||
shl %cl, %eax
|
||||
|
||||
Note that since shl could operate directly on memory, we could have:
|
||||
|
||||
push some_arg
|
||||
call func
|
||||
mov %eax, %ecx
|
||||
shl %cl, $fffc(%ebp)
|
||||
|
||||
The above example with loading the operand in a register is just to complicate
|
||||
the example and show that the algorithm should be able to handle it.
|
||||
|
||||
Let's take another example with the this-call call convention (the first argument
|
||||
is passed in %ecx).
|
||||
In this case, will_clobber() will be called only on %eax and %edx, while %ecx
|
||||
will be allocated with get_register_force ().
|
||||
Note: when a register is allocated with get_register_force(), it should be set
|
||||
to a different state as soon as possible.
|
||||
|
||||
store (local1, shl (local1, this-call (local1)))
|
||||
|
||||
instruction register status -> [%eax %ecx %edx]
|
||||
start free free free
|
||||
eax = load local1 mov free free
|
||||
/* force load in %ecx */
|
||||
ecx = load local1 mov busy free
|
||||
spill eax free busy free
|
||||
call mov free free
|
||||
/* now eax contains the right operand of the shl */
|
||||
mov %eax -> %ecx free busy free
|
||||
un-spill mov busy free
|
||||
shl %cl, %eax mov free free
|
||||
|
||||
What happens when a register that we need to allocate with get_register_force ()
|
||||
contains an operand for the next instruction?
|
||||
|
||||
instruction register status -> [%eax %ecx %edx]
|
||||
eax = load local0 mov free free
|
||||
ecx = load local1 mov mov free
|
||||
get_register_force (ecx) here.
|
||||
We have two options:
|
||||
mov %ecx, %edx
|
||||
or:
|
||||
spill %ecx
|
||||
The first option is way better (and allows the peephole pass to
|
||||
just load the value in %edx directly, instead of loading first to %ecx).
|
||||
This doesn't work, though, if the instruction clobbers the %edx register
|
||||
(like in a this-call). So, we first need to clobber the registers
|
||||
(so the state of %ecx changes to freebale and there is no issue
|
||||
with get_register_force ()).
|
||||
What if an instruction both clobbers a register and requires it as
|
||||
an operand? Lets' take the x86 idiv instruction as an example: it
|
||||
requires the dividend in edx:eax and returns the result in eax,
|
||||
with the modulus in edx.
|
||||
|
||||
store (local1, div (local1, local2))
|
||||
|
||||
instruction register status -> [%eax %ecx %edx]
|
||||
eax = load local0 mov free free
|
||||
will_clobber eax, edx free mov free
|
||||
force mov %ecx, %eax busy free free
|
||||
set %edx busy free busy
|
||||
idiv mov free free
|
||||
|
||||
Note: edx is set to free after idiv, because the modulus is not needed
|
||||
(if it was a rem, eax would have been freed).
|
||||
If we load the divisor before will_clobber(), we'll have to spill
|
||||
eax and reload it later. If we load it just after the idiv, there is no issue.
|
||||
In any case, the algorithm should give the correct results and allow the operation.
|
||||
|
||||
Working recursively on the isntructions there shouldn't be huge issues
|
||||
with this algorithm (though, of course, it's not optimal and it may
|
||||
introduce excessive spills or register moves). The advantage over the current
|
||||
local reg allocator is that:
|
||||
1) the number of spills/moves would be smaller anyway
|
||||
2) a separate peephole pass could be able to eliminate reg moves
|
||||
3) we'll be able to remove the 'forced' spills we currently do with
|
||||
the return value of method calls
|
||||
|
||||
* Issues
|
||||
|
||||
How to best integrate such a reg allocator with the burg stuff.
|
||||
|
||||
Think about a call os sparc with two arguments: they got into %o0 and %o1
|
||||
and each of them sets the register as busy. But what if the values to put there
|
||||
are themselves the result of a call? %o0 is no problem, but for all the
|
||||
next argument n the above algorithm would spill all the 0...n-1 registers...
|
||||
|
||||
* Papers
|
||||
|
||||
More complex solutions to the local register allocator problem:
|
||||
http://dimacs.rutgers.edu/TechnicalReports/abstracts/1997/97-33.html
|
||||
|
||||
Combining register allocation and instruction scheduling:
|
||||
http://citeseer.nj.nec.com/motwani95combining.html
|
||||
|
||||
More on LRA euristics:
|
||||
http://citeseer.nj.nec.com/liberatore97hardness.html
|
||||
|
||||
Linear-time optimal code scheduling for delayedload architectures
|
||||
http://www.cs.wisc.edu/~fischer/cs701.f01/inst.sched.ps.gz
|
||||
|
||||
Precise Register Allocation for Irregular Architectures
|
||||
http://citeseer.nj.nec.com/kong98precise.html
|
||||
|
||||
Allocate registers first to subtrees that need more of them.
|
||||
http://www.upb.de/cs/ag-kastens/compii/folien/comment401-409.2.pdf
|
||||
@@ -0,0 +1,98 @@
|
||||
=pod
|
||||
|
||||
=head1 Internal design document for the mono_handle_d
|
||||
|
||||
This document is designed to hold the design of the mono_handle_d and
|
||||
not as an api reference.
|
||||
|
||||
=head2 Primary goal and purpose
|
||||
|
||||
The mono_handle_d is a process which takes care of the (de)allocation
|
||||
of scratch shared memory and handles (of files, threads, mutexes,
|
||||
sockets etc. see L<WapiHandleType>) and refcounts of the
|
||||
filehandles. It is designed to be run by a user and to be fast, thus
|
||||
minimal error checking on input is done and will most likely crash if
|
||||
given a faulty package. No effort has been, or should be, made to have
|
||||
the daemon talking to machine of different endianness/size of int.
|
||||
|
||||
=head2 How to start the daemon
|
||||
|
||||
To start the daemon you either run the mono_handle_d executable or try
|
||||
to attach to the shared memory segment via L<_wapi_shm_attach> which
|
||||
will start a daemon if one does not exist.
|
||||
|
||||
=head1 Internal details
|
||||
|
||||
The daemon works by opening a socket and listening to clients. These
|
||||
clients send packages over the socket complying to L<struct
|
||||
WapiHandleRequest>.
|
||||
|
||||
=head2 Possible requests
|
||||
|
||||
=over
|
||||
|
||||
=item WapiHandleRequest_New
|
||||
|
||||
Find a handle in the shared memory segment that is free and allocate
|
||||
it to the specified type. To destroy use
|
||||
L</WapiHandleRequest_Close>. A L<WapiHandleResponse> with
|
||||
.type=WapiHandleResponseType_New will be sent back with .u.new.handle
|
||||
set to the handle that was allocated. .u.new.type is the type that was
|
||||
requested.
|
||||
|
||||
=item WapiHandleRequestType_Open
|
||||
|
||||
Increase the ref count of an already created handle. A
|
||||
L<WapiHandleResponse> with .type=WapiHandleResponseType_Open will be sent
|
||||
back with .u.new.handle set to the handle, .u.new.type is set to the
|
||||
type of handle this is.
|
||||
|
||||
=item WapiHandleRequestType_Close
|
||||
|
||||
Decrease the ref count of an already created handle. A
|
||||
L<WapiHandleResponse> with .type=WapiHandleResponseType_Close will be
|
||||
sent back with .u.close.destroy set to TRUE if ref count for this
|
||||
client reached 0.
|
||||
|
||||
=item WapiHandleRequestType_Scratch
|
||||
|
||||
Allocate a shared memory area of size .u.scratch.length in bytes. A
|
||||
L<WapiHandleResponse> with .type=WapiHandleResponseType_Scratch will be
|
||||
sent back with .u.scratch.idx set to the index into the shared
|
||||
memory's scratch area where to memory begins. (works just like
|
||||
malloc(3))
|
||||
|
||||
=item WapiHandleRequestType_Scratch
|
||||
|
||||
Deallocate a shared memory area, this must have been allocated before
|
||||
deallocating. A L<WapiHandleResponse> with
|
||||
.type=WapiHandleResponseType_ScratchFree will be sent back (works just
|
||||
like free(3))
|
||||
|
||||
=back
|
||||
|
||||
=head1 Why a daemon
|
||||
|
||||
From an email:
|
||||
|
||||
Dennis: I just have one question about the daemon... Why does it
|
||||
exist? Isn't it better performancewise to just protect the shared area
|
||||
with a mutex when allocation a new handle/shared mem segment or
|
||||
changing refcnt? It will however be a less resilient to clients that
|
||||
crash (the deamon cleans up ref'd handles if socket closes)
|
||||
|
||||
Dick: It's precisely because with a mutex the shared memory segment
|
||||
can be left in a locked state. Also, it's not so easy to clean up
|
||||
shared memory without it (you can't just mark it deleted when creating
|
||||
it, because you can't attach any more readers to the same segment
|
||||
after that). I did some minimal performance testing, and I don't
|
||||
think the daemon is particularly slow.
|
||||
|
||||
|
||||
=head1 Authors
|
||||
|
||||
Documentaion: Dennis Haney
|
||||
|
||||
Implementation: Dick Porter
|
||||
|
||||
=cut
|
||||
@@ -0,0 +1,68 @@
|
||||
We need to switch to a new register allocator.
|
||||
The current one is split in a global and a local register allocator.
|
||||
The global one can assign only callee-saves registers and happens
|
||||
on the tree-based internal representation: it assigns local variables
|
||||
to hardware registers.
|
||||
The local one happens on the linear representation on a per basic
|
||||
block basis and assigns hard registers to virtual registers (which
|
||||
hold temporary values during expression executions) and it deals also
|
||||
with the platform-specific issues (fixed registers, call conventions).
|
||||
|
||||
Moving to a different register will help solve some of the performance
|
||||
issues introduced by the above split, make the register more easily
|
||||
portable and solve some of the issues generated by dealing with trees.
|
||||
|
||||
The general design ideas are below.
|
||||
|
||||
The new allocator should have a global view of all the method, so it can be
|
||||
able to assign variables also to some of the volatile registers if possible,
|
||||
even across basic blocks (this would improve performance).
|
||||
|
||||
The allocator would be driven by per-arch declarative data, so porting
|
||||
should be easier: an architecture needs to specify register classes,
|
||||
call convention and instructions requirements (similar to the gcc code).
|
||||
|
||||
The allocator should operate on the linear representation, this way it's
|
||||
easier and faster to track usages more correctly. We need to assign virtual
|
||||
registers on a per-method basis instead of per basic block. We can assign
|
||||
virtual registers to variables, too. Note that since we fix the stack offset
|
||||
of local vars only after this step (which happens after the burg rules are run),
|
||||
some of the burg rules that try to optimize the code won't apply anymore:
|
||||
the peephole code may need to be enhanced to do the optimizations instead.
|
||||
|
||||
We need to handle floating point registers in the global allocator, too.
|
||||
|
||||
The new allocator also needs to keep track precisely of which registers
|
||||
contain references or managed pointers to allow us to move to a precise GC.
|
||||
|
||||
It may be worth to use a single increasing set of integers for the virtual
|
||||
registers, with the class of the register stored separately (unless the
|
||||
current local allocator which keeps interger and fp registers separate).
|
||||
|
||||
Since this is a large task, we need to do it in steps as much as possible.
|
||||
The first is to run the register allocator _after_ the burg rules: this
|
||||
requires a rewrite of the liveness code, too, to use linear indexes instead
|
||||
of basic-block/tree number combinations. This can be done by:
|
||||
*) allocating virtual regs to all the locals that can be register allocated
|
||||
*) running the burg rules (some may require adjustments): the local virtual
|
||||
registers are assigned starting from global-virt-regs+1, instead of the current
|
||||
hardware-regs+1, so we can tell apart global and local virt regs.
|
||||
*) running the liveness/whatever code is needed to allocate the global registers
|
||||
*) allocate the rest of the local variables to stack slots
|
||||
*) continue with the current local allocator
|
||||
|
||||
This work could take 2-3 weeks.
|
||||
|
||||
The next step is to define the kind of declarative data an architecture needs
|
||||
and assigning virtual regs to all the registers and making the allocator
|
||||
assign from the volatile registers, too.
|
||||
Note that some of the code that is currently emitted in the arch-specific
|
||||
code, will need to be emitted as instructions that the reg allocator
|
||||
can inspect: think of a method that returns the first argument which is
|
||||
received in a register: the current code copies it to either a local slot or
|
||||
to a global reg in the prolog an copies it back to the return register
|
||||
int he basic block, but since neither the regallocator nor the peephole code
|
||||
knows about the prolog code, the first store cannot be optimized away.
|
||||
The gcc code has some example of how to specify register classes in a
|
||||
declarative way.
|
||||
|
||||
@@ -0,0 +1,113 @@
|
||||
|
||||
* How to handle complex IL opcodes in an arch-independent way
|
||||
|
||||
Many IL opcodes are very simple: add, ldind etc.
|
||||
Such opcodes can be implemented with a single cpu instruction
|
||||
in most architectures (on some, a group of IL instructions
|
||||
can be converted to a single cpu op).
|
||||
There are many IL opcodes, though, that are more complex, but
|
||||
can be expressed as a series of trees or a single tree of
|
||||
simple operations. Such simple operations are architecture-independent.
|
||||
It makes sense to decompose such complex IL instructions in their
|
||||
simpler equivalent so that we gain in several ways:
|
||||
*) porting effort is easier, because only the simple instructions
|
||||
need to be implemented in arch-specific code
|
||||
*) we could apply BURG rules to the trees and do pattern matching
|
||||
on them to optimize the expressions according to the host cpu
|
||||
|
||||
The issue is: where do we do such conversion from coarse opcodes to
|
||||
simple expressions?
|
||||
|
||||
* Doing the conversion in method_to_ir ()
|
||||
|
||||
Some of these conversions can certainly be done in method_to_ir (),
|
||||
but it's not always easy to decide which are better done there and
|
||||
which in a different pass.
|
||||
For example, let's take ldlen: in the mono implementation, ldlen
|
||||
can be simply implemented with a load from a fixed position in the
|
||||
array object:
|
||||
|
||||
len = [reg + maxlen_offset]
|
||||
|
||||
However, ldlen carries also semantics information: the result is the
|
||||
length of the array, and since in the CLR arrays are of fixed size,
|
||||
this information can be useful to later do bounds check removal.
|
||||
If we convert this opcode in method_to_ir () we lost some useful
|
||||
information for further optimizations.
|
||||
|
||||
In some other ways, decomposing an opcode in method_to_ir() may
|
||||
allow for better optimizations later on (need to come up with an
|
||||
example here ...).
|
||||
|
||||
* Doing the conversion in inssel.brg
|
||||
|
||||
Some conversion may be done inside the burg rules: this has the
|
||||
disadvantage that the instruction selector is not run again on
|
||||
the resulting expression tree and we could miss some optimization
|
||||
(this is what effectively happens with the coarse opcodes in the old
|
||||
jit). This may also interfere with an efficient local register allocator.
|
||||
It may be possible to add an extension in monoburg that allows a rule
|
||||
such as:
|
||||
|
||||
recheck: LDLEN (reg) {
|
||||
create an expression tree representing LDLEN
|
||||
and return it
|
||||
}
|
||||
|
||||
When the monoburg label process gets back a recheck, it will run
|
||||
the labeling again on the resulting expression tree.
|
||||
If this is possible at all (and in an efficient way) is a
|
||||
question for dietmar:-)
|
||||
It should be noted, though, that this may not always work, since
|
||||
some complex IL opcodes may require a series of expression trees
|
||||
and handling such cases in monoburg could become quite hairy.
|
||||
For example, think of opcode that need to do multiple actions on the
|
||||
same object: this basically means a DUP...
|
||||
On the other end, if a complex opcode needs a DUP, monoburg doesn't
|
||||
actually need to create trees if it emits the instructions in
|
||||
the correct sequence and maintains the right values in the registers
|
||||
(usually the values that need a DUP are not changed...). How
|
||||
this integrates with the current register allocator is not clear, since
|
||||
that assigns registers based on the rule, but the instructions emitted
|
||||
by the rules may be different (this already happens with the current JIT
|
||||
where a MULT is replaced with lea etc...).
|
||||
|
||||
* Doing it in a separate pass.
|
||||
|
||||
Doing the conversion in a separate pass over the instructions
|
||||
is another alternative. This can be done right after method_to_ir ()
|
||||
or after the SSA pass (since the IR after the SSA pass should look
|
||||
almost like the IR we get back from method_to_ir ()).
|
||||
|
||||
This has the following advantages:
|
||||
*) monoburg will handle only the simple opcodes (makes porting easier)
|
||||
*) the instruction selection will be run on all the additional trees
|
||||
*) it's easier to support coarse opcodes that produce multiple expression
|
||||
trees (and apply the monoburg selector on all of them)
|
||||
*) the SSA optimizer will see the original opcodes and will be able to use
|
||||
the semantic info associated with them
|
||||
|
||||
The disadvantage is that this is a separate pass on the code and
|
||||
it takes time (how much has not been measured yet, though).
|
||||
|
||||
With this approach, we may also be able to have C implementations
|
||||
of some of the opcodes: this pass would insert a function call to
|
||||
the C implementation (for example in the cases when first porting
|
||||
to a new arch and implemenating some stuff may be too hard in asm).
|
||||
|
||||
* Extended basic blocks
|
||||
|
||||
IL code needs a lot of checks, bounds checks, overflow checks,
|
||||
type checks and so on. This potentially increases by a lot
|
||||
the number of basic blocks in a control flow graph. However,
|
||||
all such blocks end up with a throw opcode that gives control to the
|
||||
exception handling mechanism.
|
||||
After method_to_ir () a MonoBasicBlock can be considered a sort
|
||||
of extended basic block where the additional exits don't point
|
||||
to basic blocks in the same procedure (at least when the method
|
||||
doesn't have exception tables).
|
||||
We need to make sure the passes following method_to_ir () can cope
|
||||
with such kinds of extended basic blocks (especially the passes
|
||||
that we need to apply to all the methods: as a start, we could
|
||||
skip SSA optimizations for methods with exception clauses...)
|
||||
|
||||
+79
@@ -0,0 +1,79 @@
|
||||
mono_array_clone
|
||||
mono_array_clone_in_domain
|
||||
mono_array_full_copy
|
||||
mono_array_new
|
||||
mono_array_new_full
|
||||
mono_array_new_specific
|
||||
mono_async_result_new
|
||||
mono_class_get_allocation_ftn
|
||||
mono_class_vtable
|
||||
mono_compile_method
|
||||
mono_delegate_ctor
|
||||
mono_field_get_value
|
||||
mono_field_get_value_object
|
||||
mono_field_set_value
|
||||
mono_field_static_get_value
|
||||
mono_field_static_set_value
|
||||
mono_get_constant_value_from_blob
|
||||
mono_get_delegate_invoke
|
||||
mono_install_compile_method
|
||||
mono_install_free_method
|
||||
mono_install_handler
|
||||
mono_install_remoting_trampoline
|
||||
mono_install_runtime_invoke
|
||||
mono_install_trampoline
|
||||
mono_ldstr
|
||||
mono_load_remote_field
|
||||
mono_load_remote_field_new
|
||||
mono_message_init
|
||||
mono_message_invoke
|
||||
mono_method_call_message_new
|
||||
mono_method_return_message_restore
|
||||
mono_object_castclass_mbyref
|
||||
mono_object_clone
|
||||
mono_object_get_class
|
||||
mono_object_get_domain
|
||||
mono_object_get_virtual_method
|
||||
mono_object_isinst
|
||||
mono_object_isinst_mbyref
|
||||
mono_object_new
|
||||
mono_object_new_alloc_specific
|
||||
mono_object_new_fast
|
||||
mono_object_new_from_token
|
||||
mono_object_new_specific
|
||||
mono_object_unbox
|
||||
mono_print_unhandled_exception
|
||||
mono_property_get_value
|
||||
mono_property_set_value
|
||||
mono_raise_exception
|
||||
mono_release_type_locks
|
||||
mono_remote_class
|
||||
mono_remote_class_vtable
|
||||
mono_remoting_invoke
|
||||
mono_runtime_class_init
|
||||
mono_runtime_delegate_invoke
|
||||
mono_runtime_exec_main
|
||||
mono_runtime_exec_managed_code
|
||||
mono_runtime_free_method
|
||||
mono_runtime_get_main_args
|
||||
mono_runtime_invoke
|
||||
mono_runtime_invoke_array
|
||||
mono_runtime_object_init
|
||||
mono_runtime_run_main
|
||||
mono_store_remote_field
|
||||
mono_store_remote_field_new
|
||||
mono_string_from_utf16
|
||||
mono_string_intern
|
||||
mono_string_is_interned
|
||||
mono_string_new
|
||||
mono_string_new_len
|
||||
mono_string_new_size
|
||||
mono_string_new_utf16
|
||||
mono_string_new_wrapper
|
||||
mono_string_to_utf16
|
||||
mono_string_to_utf8
|
||||
mono_type_initialization_init
|
||||
mono_unhandled_exception
|
||||
mono_upgrade_remote_class
|
||||
mono_value_box
|
||||
mono_wait_handle_new
|
||||
+829
@@ -0,0 +1,829 @@
|
||||
dlfree
|
||||
dlmalloc
|
||||
dlmemalign
|
||||
free_list_index_of
|
||||
g_printerr
|
||||
g_ptr_array_remove_fast
|
||||
invoke_protected_memory_method
|
||||
mini_debugger_init
|
||||
mini_debugger_main
|
||||
mini_debugger_set_attach_ok
|
||||
mini_debug_running_inside_mdb
|
||||
mini_emit_initobj
|
||||
mini_emit_stobj
|
||||
mono_add_internal_call
|
||||
mono_aot_register_globals
|
||||
mono_aot_register_module
|
||||
mono_array_addr_with_size
|
||||
mono_array_class_get
|
||||
mono_array_clone
|
||||
mono_array_element_size
|
||||
mono_array_length
|
||||
mono_array_new
|
||||
mono_array_new_full
|
||||
mono_array_new_specific
|
||||
mono_assemblies_cleanup
|
||||
mono_assembly_close
|
||||
mono_assembly_get_image
|
||||
mono_assembly_get_main
|
||||
mono_assembly_get_object
|
||||
mono_assembly_getrootdir
|
||||
mono_assembly_load
|
||||
mono_assembly_loaded
|
||||
mono_assembly_loaded_full
|
||||
mono_assembly_load_full
|
||||
mono_assembly_name_free
|
||||
mono_assembly_name_get_culture
|
||||
mono_assembly_name_get_name
|
||||
mono_assembly_name_get_pubkeytoken
|
||||
mono_assembly_name_get_version
|
||||
mono_assembly_name_new
|
||||
mono_assembly_names_equal
|
||||
mono_assembly_open
|
||||
mono_bitset_alloc_size
|
||||
mono_bitset_clear
|
||||
mono_bitset_clear_all
|
||||
mono_bitset_clone
|
||||
mono_bitset_copyto
|
||||
mono_bitset_count
|
||||
mono_bitset_equal
|
||||
mono_bitset_find_first
|
||||
mono_bitset_find_first_unset
|
||||
mono_bitset_find_last
|
||||
mono_bitset_find_start
|
||||
mono_bitset_foreach
|
||||
mono_bitset_free
|
||||
mono_bitset_intersection
|
||||
mono_bitset_intersection_2
|
||||
mono_bitset_invert
|
||||
mono_bitset_mem_new
|
||||
mono_bitset_new
|
||||
mono_bitset_set
|
||||
mono_bitset_set_all
|
||||
mono_bitset_size
|
||||
mono_bitset_sub
|
||||
mono_bitset_test
|
||||
mono_bitset_test_bulk
|
||||
mono_bitset_union
|
||||
mono_bounded_array_class_get
|
||||
mono_breakpoint_clean_code
|
||||
mono_check_corlib_version
|
||||
mono_class_array_element_size
|
||||
mono_class_data_size
|
||||
mono_class_describe_statics
|
||||
mono_class_enum_basetype
|
||||
mono_class_from_generic_parameter
|
||||
mono_class_from_mono_type
|
||||
mono_class_from_name
|
||||
mono_class_from_name_case
|
||||
mono_class_from_typeref
|
||||
mono_class_get
|
||||
mono_class_get_byref_type
|
||||
mono_class_get_element_class
|
||||
mono_class_get_events
|
||||
mono_class_get_event_token
|
||||
mono_class_get_field
|
||||
mono_class_get_field_from_name
|
||||
mono_class_get_fields
|
||||
mono_class_get_field_token
|
||||
mono_class_get_flags
|
||||
mono_class_get_full
|
||||
mono_class_get_image
|
||||
mono_class_get_interfaces
|
||||
mono_class_get_method_from_name
|
||||
mono_class_get_method_from_name_flags
|
||||
mono_class_get_methods
|
||||
mono_class_get_name
|
||||
mono_class_get_namespace
|
||||
mono_class_get_nested_types
|
||||
mono_class_get_nesting_type
|
||||
mono_class_get_parent
|
||||
mono_class_get_properties
|
||||
mono_class_get_property_from_name
|
||||
mono_class_get_property_token
|
||||
mono_class_get_rank
|
||||
mono_class_get_type
|
||||
mono_class_get_type_token
|
||||
mono_class_inflate_generic_method
|
||||
mono_class_inflate_generic_type
|
||||
mono_class_init
|
||||
mono_class_instance_size
|
||||
mono_class_interface_offset
|
||||
mono_class_is_assignable_from
|
||||
mono_class_is_enum
|
||||
mono_class_is_subclass_of
|
||||
mono_class_is_valid_enum
|
||||
mono_class_is_valuetype
|
||||
mono_class_min_align
|
||||
mono_class_name_from_token
|
||||
mono_class_num_events
|
||||
mono_class_num_fields
|
||||
mono_class_num_methods
|
||||
mono_class_num_properties
|
||||
mono_class_value_size
|
||||
mono_class_vtable
|
||||
mono_cli_rva_image_map
|
||||
mono_code_manager_commit
|
||||
mono_code_manager_destroy
|
||||
mono_code_manager_foreach
|
||||
mono_code_manager_invalidate
|
||||
mono_code_manager_new
|
||||
mono_code_manager_new_dynamic
|
||||
mono_code_manager_reserve
|
||||
mono_code_manager_reserve_align
|
||||
mono_code_manager_set_read_only
|
||||
mono_code_manager_size
|
||||
mono_compile_method
|
||||
mono_config_for_assembly
|
||||
mono_config_parse
|
||||
mono_config_parse_memory
|
||||
mono_config_string_for_assembly_file
|
||||
mono_context_get
|
||||
mono_context_get_desc
|
||||
mono_context_set
|
||||
mono_counters_cleanup
|
||||
mono_counters_dump
|
||||
mono_counters_enable
|
||||
mono_counters_register
|
||||
mono_custom_attrs_construct
|
||||
mono_custom_attrs_free
|
||||
mono_custom_attrs_from_assembly
|
||||
mono_custom_attrs_from_class
|
||||
mono_custom_attrs_from_event
|
||||
mono_custom_attrs_from_field
|
||||
mono_custom_attrs_from_index
|
||||
mono_custom_attrs_from_method
|
||||
mono_custom_attrs_from_param
|
||||
mono_custom_attrs_from_property
|
||||
mono_custom_attrs_get_attr
|
||||
mono_custom_attrs_has_attr
|
||||
mono_debug_add_method
|
||||
_mono_debug_address_from_il_offset
|
||||
mono_debug_close_image
|
||||
mono_debug_close_mono_symbol_file
|
||||
mono_debug_domain_create
|
||||
mono_debug_domain_unload
|
||||
mono_debug_find_method
|
||||
mono_debug_free_source_location
|
||||
mono_debugger_abort_runtime_invoke
|
||||
mono_debugger_breakpoint_callback
|
||||
mono_debugger_call_exception_handler
|
||||
mono_debugger_check_breakpoints
|
||||
mono_debugger_check_interruption
|
||||
mono_debugger_check_runtime_version
|
||||
mono_debugger_class_initialized
|
||||
mono_debugger_event
|
||||
mono_debugger_event_create_appdomain
|
||||
mono_debugger_event_unload_appdomain
|
||||
mono_debugger_extended_notification
|
||||
mono_debugger_handle_exception
|
||||
mono_debugger_insert_breakpoint
|
||||
mono_debugger_insert_breakpoint_full
|
||||
mono_debugger_insert_method_breakpoint
|
||||
mono_debugger_lock
|
||||
mono_debugger_method_has_breakpoint
|
||||
MONO_DEBUGGER__notification_function
|
||||
mono_debugger_register_class_init_callback
|
||||
mono_debugger_remove_breakpoint
|
||||
mono_debugger_remove_class_init_callback
|
||||
mono_debugger_remove_method_breakpoint
|
||||
mono_debugger_run_finally
|
||||
mono_debugger_runtime_invoke
|
||||
mono_debugger_thread_cleanup
|
||||
mono_debugger_thread_created
|
||||
_mono_debugger_throw_exception
|
||||
mono_debugger_trampoline_compiled
|
||||
_mono_debugger_unhandled_exception
|
||||
mono_debugger_unlock
|
||||
mono_debug_il_offset_from_address
|
||||
mono_debug_list_add
|
||||
mono_debug_list_remove
|
||||
mono_debug_lookup_locals
|
||||
mono_debug_lookup_method
|
||||
mono_debug_lookup_method_addresses
|
||||
mono_debug_lookup_source_location
|
||||
mono_debug_open_image_from_memory
|
||||
mono_debug_open_mono_symbols
|
||||
mono_debug_print_stack_frame
|
||||
mono_debug_print_vars
|
||||
mono_debug_symfile_get_line_numbers
|
||||
mono_debug_symfile_lookup_locals
|
||||
mono_debug_symfile_lookup_location
|
||||
mono_debug_symfile_lookup_method
|
||||
mono_debug_using_mono_debugger
|
||||
mono_declsec_flags_from_assembly
|
||||
mono_declsec_flags_from_class
|
||||
mono_declsec_flags_from_method
|
||||
mono_declsec_get_assembly_action
|
||||
mono_declsec_get_class_action
|
||||
mono_declsec_get_demands
|
||||
mono_declsec_get_inheritdemands_class
|
||||
mono_declsec_get_inheritdemands_method
|
||||
mono_declsec_get_linkdemands
|
||||
mono_declsec_get_method_action
|
||||
mono_digest_get_public_token
|
||||
mono_disasm_code
|
||||
mono_disasm_code_one
|
||||
mono_dllmap_insert
|
||||
mono_domain_assembly_open
|
||||
mono_domain_create
|
||||
mono_domain_create_appdomain
|
||||
mono_domain_finalize
|
||||
mono_domain_foreach
|
||||
mono_domain_free
|
||||
mono_domain_from_appdomain
|
||||
mono_domain_get
|
||||
mono_domain_get_by_id
|
||||
mono_domain_get_id
|
||||
mono_domain_has_type_resolve
|
||||
mono_domain_is_unloading
|
||||
mono_domain_owns_vtable_slot
|
||||
mono_domain_set
|
||||
mono_domain_set_internal
|
||||
mono_domain_try_type_resolve
|
||||
mono_domain_try_unload
|
||||
mono_domain_unload
|
||||
mono_emit_native_call
|
||||
mono_environment_exitcode_get
|
||||
mono_environment_exitcode_set
|
||||
mono_error_cleanup
|
||||
mono_error_get_error_code
|
||||
mono_error_get_message
|
||||
mono_error_init
|
||||
mono_error_init_flags
|
||||
mono_error_ok
|
||||
mono_escape_uri_string
|
||||
mono_event_get_add_method
|
||||
mono_event_get_flags
|
||||
mono_event_get_name
|
||||
mono_event_get_object
|
||||
mono_event_get_parent
|
||||
mono_event_get_raise_method
|
||||
mono_event_get_remove_method
|
||||
mono_exception_from_name
|
||||
mono_exception_from_name_domain
|
||||
mono_exception_from_name_msg
|
||||
mono_exception_from_name_two_strings
|
||||
mono_exception_from_token
|
||||
mono_exception_from_token_two_strings
|
||||
mono_field_from_token
|
||||
mono_field_full_name
|
||||
mono_field_get_data
|
||||
mono_field_get_flags
|
||||
mono_field_get_name
|
||||
mono_field_get_object
|
||||
mono_field_get_offset
|
||||
mono_field_get_parent
|
||||
mono_field_get_type
|
||||
mono_field_get_value
|
||||
mono_field_get_value_object
|
||||
mono_field_set_value
|
||||
mono_field_static_get_value
|
||||
mono_field_static_set_value
|
||||
mono_file_map
|
||||
mono_file_map_close
|
||||
mono_file_map_fd
|
||||
mono_file_map_open
|
||||
mono_file_map_size
|
||||
mono_file_unmap
|
||||
mono_free
|
||||
mono_free_bstr
|
||||
mono_free_method
|
||||
mono_free_verify_list
|
||||
mono_gc_collect
|
||||
mono_gc_collection_count
|
||||
mono_gc_enable_events
|
||||
mono_gc_get_generation
|
||||
mono_gc_get_heap_size
|
||||
mono_gc_get_used_size
|
||||
mono_gchandle_free
|
||||
mono_gchandle_get_target
|
||||
mono_gchandle_new
|
||||
mono_gchandle_new_weakref
|
||||
mono_gc_invoke_finalizers
|
||||
mono_gc_is_finalizer_thread
|
||||
mono_gc_max_generation
|
||||
mono_gc_out_of_memory
|
||||
mono_gc_wbarrier_arrayref_copy
|
||||
mono_gc_wbarrier_generic_nostore
|
||||
mono_gc_wbarrier_generic_store
|
||||
mono_gc_wbarrier_generic_store_atomic
|
||||
mono_gc_wbarrier_object_copy
|
||||
mono_gc_wbarrier_set_arrayref
|
||||
mono_gc_wbarrier_set_field
|
||||
mono_gc_wbarrier_value_copy
|
||||
mono_get_array_class
|
||||
mono_get_boolean_class
|
||||
mono_get_byte_class
|
||||
mono_get_char_class
|
||||
mono_get_config_dir
|
||||
mono_get_corlib
|
||||
mono_get_dbnull_object
|
||||
mono_get_delegate_invoke
|
||||
mono_get_double_class
|
||||
mono_get_enum_class
|
||||
mono_get_exception_appdomain_unloaded
|
||||
mono_get_exception_argument
|
||||
mono_get_exception_argument_null
|
||||
mono_get_exception_argument_out_of_range
|
||||
mono_get_exception_arithmetic
|
||||
mono_get_exception_array_type_mismatch
|
||||
mono_get_exception_bad_image_format
|
||||
mono_get_exception_bad_image_format2
|
||||
mono_get_exception_cannot_unload_appdomain
|
||||
mono_get_exception_class
|
||||
mono_get_exception_divide_by_zero
|
||||
mono_get_exception_execution_engine
|
||||
mono_get_exception_field_access
|
||||
mono_get_exception_file_not_found
|
||||
mono_get_exception_file_not_found2
|
||||
mono_get_exception_index_out_of_range
|
||||
mono_get_exception_invalid_cast
|
||||
mono_get_exception_invalid_operation
|
||||
mono_get_exception_io
|
||||
mono_get_exception_method_access
|
||||
mono_get_exception_missing_field
|
||||
mono_get_exception_missing_method
|
||||
mono_get_exception_not_implemented
|
||||
mono_get_exception_not_supported
|
||||
mono_get_exception_null_reference
|
||||
mono_get_exception_out_of_memory
|
||||
mono_get_exception_overflow
|
||||
mono_get_exception_reflection_type_load
|
||||
mono_get_exception_security
|
||||
mono_get_exception_serialization
|
||||
mono_get_exception_stack_overflow
|
||||
mono_get_exception_synchronization_lock
|
||||
mono_get_exception_thread_abort
|
||||
mono_get_exception_thread_interrupted
|
||||
mono_get_exception_thread_state
|
||||
mono_get_exception_type_initialization
|
||||
mono_get_exception_type_load
|
||||
mono_get_int16_class
|
||||
mono_get_int32_class
|
||||
mono_get_int64_class
|
||||
mono_get_intptr_class
|
||||
mono_get_machine_config
|
||||
mono_get_method
|
||||
mono_get_method_full
|
||||
mono_get_object_class
|
||||
mono_get_root_domain
|
||||
mono_get_sbyte_class
|
||||
mono_get_single_class
|
||||
mono_get_string_class
|
||||
mono_get_thread_class
|
||||
mono_get_trampoline_func
|
||||
mono_get_uint16_class
|
||||
mono_get_uint32_class
|
||||
mono_get_uint64_class
|
||||
mono_get_uintptr_class
|
||||
mono_get_void_class
|
||||
mono_g_hash_table_destroy
|
||||
mono_g_hash_table_find
|
||||
mono_g_hash_table_foreach
|
||||
mono_g_hash_table_foreach_remove
|
||||
mono_g_hash_table_insert
|
||||
mono_g_hash_table_lookup
|
||||
mono_g_hash_table_lookup_extended
|
||||
mono_g_hash_table_new
|
||||
mono_g_hash_table_new_full
|
||||
mono_g_hash_table_new_type
|
||||
mono_g_hash_table_remove
|
||||
mono_g_hash_table_replace
|
||||
mono_g_hash_table_size
|
||||
mono_guid_to_string
|
||||
mono_hazard_pointer_get
|
||||
mono_image_addref
|
||||
mono_image_close
|
||||
mono_image_ensure_section
|
||||
mono_image_ensure_section_idx
|
||||
mono_image_fixup_vtable
|
||||
mono_image_get_assembly
|
||||
mono_image_get_entry_point
|
||||
mono_image_get_filename
|
||||
mono_image_get_guid
|
||||
mono_image_get_name
|
||||
mono_image_get_public_key
|
||||
mono_image_get_resource
|
||||
mono_image_get_strong_name
|
||||
mono_image_get_table_info
|
||||
mono_image_get_table_rows
|
||||
mono_image_has_authenticode_entry
|
||||
mono_image_is_dynamic
|
||||
mono_image_loaded
|
||||
mono_image_loaded_by_guid
|
||||
mono_image_loaded_by_guid_full
|
||||
mono_image_loaded_full
|
||||
mono_image_load_file_for_image
|
||||
mono_image_lookup_resource
|
||||
mono_image_open
|
||||
mono_image_open_from_data
|
||||
mono_image_open_from_data_full
|
||||
mono_image_open_from_data_with_name
|
||||
mono_image_open_full
|
||||
mono_image_rva_map
|
||||
mono_images_cleanup
|
||||
mono_image_strerror
|
||||
mono_image_strong_name_position
|
||||
mono_init
|
||||
mono_init_from_assembly
|
||||
mono_init_version
|
||||
mono_install_assembly_load_hook
|
||||
mono_install_assembly_postload_refonly_search_hook
|
||||
mono_install_assembly_postload_search_hook
|
||||
mono_install_assembly_preload_hook
|
||||
mono_install_assembly_refonly_preload_hook
|
||||
mono_install_assembly_refonly_search_hook
|
||||
mono_install_assembly_search_hook
|
||||
mono_install_runtime_cleanup
|
||||
mono_install_threadpool_item_hooks
|
||||
mono_install_threadpool_thread_hooks
|
||||
mono_inst_name
|
||||
mono_is_debugger_attached
|
||||
mono_jit_cleanup
|
||||
mono_jit_exec
|
||||
mono_jit_info_get_code_size
|
||||
mono_jit_info_get_code_start
|
||||
mono_jit_info_get_method
|
||||
mono_jit_info_table_find
|
||||
mono_jit_init
|
||||
mono_jit_init_version
|
||||
mono_jit_parse_options
|
||||
mono_jit_set_aot_only
|
||||
mono_jit_set_trace_options
|
||||
mono_ldstr
|
||||
mono_ldtoken
|
||||
mono_llvm_build_aligned_load
|
||||
mono_llvm_build_alloca
|
||||
mono_llvm_build_load
|
||||
mono_llvm_create_ee
|
||||
mono_llvm_dispose_ee
|
||||
mono_llvm_dump_value
|
||||
mono_llvm_optimize_method
|
||||
mono_llvm_replace_uses_of
|
||||
mono_load_remote_field
|
||||
mono_load_remote_field_new
|
||||
mono_local_deadce
|
||||
mono_locks_dump
|
||||
mono_lookup_internal_call
|
||||
mono_lookup_pinvoke_call
|
||||
mono_main
|
||||
mono_marshal_string_to_utf16
|
||||
mono_md5_final
|
||||
mono_md5_get_digest
|
||||
mono_md5_get_digest_from_file
|
||||
mono_md5_init
|
||||
mono_md5_update
|
||||
mono_mempool_alloc
|
||||
mono_mempool_alloc0
|
||||
mono_mempool_contains_addr
|
||||
mono_mempool_destroy
|
||||
mono_mempool_empty
|
||||
mono_mempool_get_allocated
|
||||
mono_mempool_invalidate
|
||||
mono_mempool_new
|
||||
mono_mempool_new_size
|
||||
mono_mempool_stats
|
||||
mono_mempool_strdup
|
||||
mono_metadata_blob_heap
|
||||
mono_metadata_cleanup
|
||||
mono_metadata_compute_size
|
||||
mono_metadata_custom_attrs_from_index
|
||||
mono_metadata_declsec_from_index
|
||||
mono_metadata_decode_blob_size
|
||||
mono_metadata_decode_row
|
||||
mono_metadata_decode_row_col
|
||||
mono_metadata_decode_signed_value
|
||||
mono_metadata_decode_table_row
|
||||
mono_metadata_decode_table_row_col
|
||||
mono_metadata_decode_value
|
||||
mono_metadata_encode_value
|
||||
mono_metadata_events_from_typedef
|
||||
mono_metadata_field_info
|
||||
mono_metadata_field_info_with_mempool
|
||||
mono_metadata_free_array
|
||||
mono_metadata_free_inflated_signature
|
||||
mono_metadata_free_marshal_spec
|
||||
mono_metadata_free_method_signature
|
||||
mono_metadata_free_mh
|
||||
mono_metadata_free_type
|
||||
mono_metadata_generic_class_is_valuetype
|
||||
mono_metadata_get_constant_index
|
||||
mono_metadata_get_inflated_signature
|
||||
mono_metadata_get_marshal_info
|
||||
mono_metadata_guid_heap
|
||||
mono_metadata_implmap_from_method
|
||||
mono_metadata_interfaces_from_typedef
|
||||
mono_metadata_load_generic_params
|
||||
mono_metadata_locate
|
||||
mono_metadata_locate_token
|
||||
mono_metadata_methods_from_event
|
||||
mono_metadata_methods_from_property
|
||||
mono_metadata_nested_in_typedef
|
||||
mono_metadata_nesting_typedef
|
||||
mono_metadata_packing_from_typedef
|
||||
mono_metadata_parse_array
|
||||
mono_metadata_parse_custom_mod
|
||||
mono_metadata_parse_field_type
|
||||
mono_metadata_parse_marshal_spec
|
||||
mono_metadata_parse_method_signature
|
||||
mono_metadata_parse_method_signature_full
|
||||
mono_metadata_parse_mh
|
||||
mono_metadata_parse_mh_full
|
||||
mono_metadata_parse_param
|
||||
mono_metadata_parse_signature
|
||||
mono_metadata_parse_type
|
||||
mono_metadata_parse_typedef_or_ref
|
||||
mono_metadata_parse_type_full
|
||||
mono_metadata_properties_from_typedef
|
||||
mono_metadata_signature_alloc
|
||||
mono_metadata_signature_dup
|
||||
mono_metadata_signature_equal
|
||||
mono_metadata_string_heap
|
||||
mono_metadata_token_from_dor
|
||||
mono_metadata_translate_token_index
|
||||
mono_metadata_typedef_from_field
|
||||
mono_metadata_typedef_from_method
|
||||
mono_metadata_type_equal
|
||||
mono_metadata_type_hash
|
||||
mono_metadata_user_string
|
||||
mono_method_body_get_object
|
||||
mono_method_can_access_field
|
||||
mono_method_can_access_method
|
||||
mono_method_desc_free
|
||||
mono_method_desc_from_method
|
||||
mono_method_desc_full_match
|
||||
mono_method_desc_match
|
||||
mono_method_desc_new
|
||||
mono_method_desc_search_in_class
|
||||
mono_method_desc_search_in_image
|
||||
mono_method_full_name
|
||||
mono_method_get_class
|
||||
mono_method_get_flags
|
||||
mono_method_get_generic_container
|
||||
mono_method_get_header
|
||||
mono_method_get_index
|
||||
mono_method_get_last_managed
|
||||
mono_method_get_marshal_info
|
||||
mono_method_get_name
|
||||
mono_method_get_object
|
||||
mono_method_get_param_names
|
||||
mono_method_get_param_token
|
||||
mono_method_get_signature
|
||||
mono_method_get_signature_full
|
||||
mono_method_get_token
|
||||
mono_method_get_unmanaged_thunk
|
||||
mono_method_has_marshal_info
|
||||
mono_method_header_get_clauses
|
||||
mono_method_header_get_code
|
||||
mono_method_header_get_locals
|
||||
mono_method_header_get_num_clauses
|
||||
mono_method_signature
|
||||
mono_method_verify
|
||||
mono_mlist_alloc
|
||||
mono_mlist_append
|
||||
mono_mlist_get_data
|
||||
mono_mlist_last
|
||||
mono_mlist_length
|
||||
mono_mlist_next
|
||||
mono_mlist_prepend
|
||||
mono_mlist_remove_item
|
||||
mono_mlist_set_data
|
||||
mono_mlist_set_next
|
||||
mono_module_file_get_object
|
||||
mono_module_get_object
|
||||
mono_monitor_enter
|
||||
mono_monitor_exit
|
||||
mono_monitor_try_enter
|
||||
mono_mprotect
|
||||
mono_object_castclass_mbyref
|
||||
mono_object_clone
|
||||
mono_object_describe
|
||||
mono_object_describe_fields
|
||||
mono_object_get_class
|
||||
mono_object_get_domain
|
||||
mono_object_get_size
|
||||
mono_object_get_virtual_method
|
||||
mono_object_is_alive
|
||||
mono_object_isinst
|
||||
mono_object_isinst_mbyref
|
||||
mono_object_new
|
||||
mono_object_new_alloc_specific
|
||||
mono_object_new_fast
|
||||
mono_object_new_from_token
|
||||
mono_object_new_specific
|
||||
mono_object_unbox
|
||||
mono_opcode_name
|
||||
mono_opcode_value
|
||||
mono_op_to_op_imm_noemul
|
||||
mono_pagesize
|
||||
mono_param_get_objects
|
||||
mono_parse_default_optimizations
|
||||
mono_path_canonicalize
|
||||
mono_path_resolve_symlinks
|
||||
mono_pe_file_open
|
||||
mono_perfcounters_init
|
||||
mono_personality
|
||||
mono_pmip
|
||||
mono_print_method_from_ip
|
||||
mono_print_thread_dump
|
||||
mono_print_thread_dump_from_ctx
|
||||
mono_print_unhandled_exception
|
||||
mono_profiler_coverage_get
|
||||
mono_profiler_get_events
|
||||
mono_profiler_install
|
||||
mono_profiler_install_allocation
|
||||
mono_profiler_install_appdomain
|
||||
mono_profiler_install_assembly
|
||||
mono_profiler_install_class
|
||||
mono_profiler_install_code_buffer_new
|
||||
mono_profiler_install_code_chunk_destroy
|
||||
mono_profiler_install_code_chunk_new
|
||||
mono_profiler_install_coverage_filter
|
||||
mono_profiler_install_enter_leave
|
||||
mono_profiler_install_exception
|
||||
mono_profiler_install_gc
|
||||
mono_profiler_install_gc_moves
|
||||
mono_profiler_install_iomap
|
||||
mono_profiler_install_jit_compile
|
||||
mono_profiler_install_jit_end
|
||||
mono_profiler_install_method_free
|
||||
mono_profiler_install_method_invoke
|
||||
mono_profiler_install_module
|
||||
mono_profiler_install_monitor
|
||||
mono_profiler_install_runtime_initialized
|
||||
mono_profiler_install_statistical
|
||||
mono_profiler_install_statistical_call_chain
|
||||
mono_profiler_install_thread
|
||||
mono_profiler_install_transition
|
||||
mono_profiler_load
|
||||
mono_profiler_set_events
|
||||
mono_property_get_flags
|
||||
mono_property_get_get_method
|
||||
mono_property_get_name
|
||||
mono_property_get_object
|
||||
mono_property_get_parent
|
||||
mono_property_get_set_method
|
||||
mono_property_get_value
|
||||
mono_property_hash_destroy
|
||||
mono_property_hash_insert
|
||||
mono_property_hash_lookup
|
||||
mono_property_hash_new
|
||||
mono_property_hash_remove_object
|
||||
mono_property_set_value
|
||||
mono_ptr_class_get
|
||||
mono_raise_exception
|
||||
mono_reflection_free_type_info
|
||||
mono_reflection_get_custom_attrs
|
||||
mono_reflection_get_custom_attrs_blob
|
||||
mono_reflection_get_custom_attrs_by_type
|
||||
mono_reflection_get_custom_attrs_data
|
||||
mono_reflection_get_custom_attrs_info
|
||||
mono_reflection_get_token
|
||||
mono_reflection_get_type
|
||||
mono_reflection_parse_type
|
||||
mono_reflection_type_from_name
|
||||
mono_register_bundled_assemblies
|
||||
mono_register_machine_config
|
||||
mono_replace_ins
|
||||
mono_runtime_class_init
|
||||
mono_runtime_cleanup
|
||||
mono_runtime_delegate_invoke
|
||||
mono_runtime_exec_main
|
||||
mono_runtime_exec_managed_code
|
||||
mono_runtime_get_main_args
|
||||
mono_runtime_init
|
||||
mono_runtime_invoke
|
||||
mono_runtime_invoke_array
|
||||
mono_runtime_is_shutting_down
|
||||
mono_runtime_object_init
|
||||
mono_runtime_quit
|
||||
mono_runtime_run_main
|
||||
mono_security_core_clr_require_elevated_permissions
|
||||
mono_security_enable_core_clr
|
||||
mono_security_set_core_clr_platform_callback
|
||||
mono_sem_post
|
||||
mono_sem_timedwait
|
||||
mono_sem_wait
|
||||
mono_set_break_policy
|
||||
mono_set_defaults
|
||||
mono_set_dirs
|
||||
mono_set_is_debugger_attached
|
||||
mono_set_signal_chaining
|
||||
mono_sha1_final
|
||||
mono_sha1_get_digest
|
||||
mono_sha1_get_digest_from_file
|
||||
mono_sha1_init
|
||||
mono_sha1_update
|
||||
mono_signature_explicit_this
|
||||
mono_signature_get_call_conv
|
||||
mono_signature_get_desc
|
||||
mono_signature_get_param_count
|
||||
mono_signature_get_params
|
||||
mono_signature_get_return_type
|
||||
mono_signature_hash
|
||||
mono_signature_is_instance
|
||||
mono_signature_vararg_start
|
||||
mono_signbit_double
|
||||
mono_signbit_float
|
||||
mono_stack_walk
|
||||
mono_stack_walk_no_il
|
||||
mono_store_remote_field
|
||||
mono_store_remote_field_new
|
||||
mono_string_chars
|
||||
mono_string_equal
|
||||
mono_string_from_bstr
|
||||
mono_string_from_utf16
|
||||
mono_string_hash
|
||||
mono_stringify_assembly_name
|
||||
mono_string_intern
|
||||
mono_string_is_interned
|
||||
mono_string_length
|
||||
mono_string_new
|
||||
mono_string_new_len
|
||||
mono_string_new_size
|
||||
mono_string_new_utf16
|
||||
mono_string_new_wrapper
|
||||
mono_string_to_utf16
|
||||
mono_string_to_utf8
|
||||
mono_table_info_get_rows
|
||||
mono_thread_attach
|
||||
mono_thread_cleanup
|
||||
mono_thread_create
|
||||
mono_thread_current
|
||||
mono_thread_detach
|
||||
mono_thread_exit
|
||||
mono_thread_get_main
|
||||
mono_thread_get_undeniable_exception
|
||||
mono_thread_hazardous_free_or_queue
|
||||
mono_thread_hazardous_try_free_all
|
||||
mono_thread_manage
|
||||
mono_thread_new_init
|
||||
mono_thread_set_main
|
||||
mono_thread_set_manage_callback
|
||||
mono_threads_get_default_stacksize
|
||||
mono_threads_install_cleanup
|
||||
mono_threads_request_thread_dump
|
||||
mono_threads_set_default_stacksize
|
||||
mono_thread_stop
|
||||
mono_trace_set_level_string
|
||||
mono_trace_set_mask_string
|
||||
mono_type_create_from_typespec
|
||||
mono_type_full_name
|
||||
mono_type_generic_inst_is_valuetype
|
||||
mono_type_get_array_type
|
||||
mono_type_get_class
|
||||
mono_type_get_desc
|
||||
mono_type_get_modifiers
|
||||
mono_type_get_name
|
||||
mono_type_get_object
|
||||
mono_type_get_ptr_type
|
||||
mono_type_get_signature
|
||||
mono_type_get_type
|
||||
mono_type_get_underlying_type
|
||||
mono_type_is_byref
|
||||
mono_type_is_pointer
|
||||
mono_type_is_reference
|
||||
mono_type_is_struct
|
||||
mono_type_is_valid_enum_basetype
|
||||
mono_type_is_void
|
||||
mono_type_size
|
||||
mono_type_stack_size
|
||||
mono_type_to_unmanaged
|
||||
mono_unhandled_exception
|
||||
mono_unicode_from_external
|
||||
mono_unicode_to_external
|
||||
mono_upgrade_remote_class_wrapper
|
||||
mono_utf8_from_external
|
||||
mono_utf8_validate_and_len
|
||||
mono_utf8_validate_and_len_with_bounds
|
||||
mono_valloc
|
||||
mono_value_box
|
||||
mono_value_copy
|
||||
mono_value_copy_array
|
||||
mono_value_describe_fields
|
||||
mono_verify_corlib
|
||||
mono_vfree
|
||||
mono_vtable_get_static_field_data
|
||||
mono_walk_stack
|
||||
mono_win32_compat_CopyMemory
|
||||
mono_win32_compat_FillMemory
|
||||
mono_win32_compat_MoveMemory
|
||||
mono_win32_compat_ZeroMemory
|
||||
_ZN20MonoJITMemoryManager11AllocateGOTEv
|
||||
_ZN20MonoJITMemoryManager12allocateStubEPKN4llvm11GlobalValueEjj
|
||||
_ZN20MonoJITMemoryManager13allocateSpaceEij
|
||||
_ZN20MonoJITMemoryManager13SetDlsymTableEPv
|
||||
_ZN20MonoJITMemoryManager14allocateGlobalEjj
|
||||
_ZN20MonoJITMemoryManager15endFunctionBodyEPKN4llvm8FunctionEPhS4_
|
||||
_ZN20MonoJITMemoryManager17endExceptionTableEPKN4llvm8FunctionEPhS4_S4_
|
||||
_ZN20MonoJITMemoryManager17setMemoryWritableEv
|
||||
_ZN20MonoJITMemoryManager17startFunctionBodyEPKN4llvm8FunctionERj
|
||||
_ZN20MonoJITMemoryManager19setMemoryExecutableEv
|
||||
_ZN20MonoJITMemoryManager19startExceptionTableEPKN4llvm8FunctionERj
|
||||
_ZN20MonoJITMemoryManager24deallocateMemForFunctionEPKN4llvm8FunctionE
|
||||
_ZN20MonoJITMemoryManagerC1Ev
|
||||
_ZN20MonoJITMemoryManagerC2Ev
|
||||
_ZN20MonoJITMemoryManagerD0Ev
|
||||
_ZN20MonoJITMemoryManagerD1Ev
|
||||
_ZN20MonoJITMemoryManagerD2Ev
|
||||
@@ -0,0 +1,49 @@
|
||||
With this change, we bundle Reactive Extensions from Microsoft.
|
||||
|
||||
Steps to do:
|
||||
|
||||
- Until we add submodule, check out Rx sources from http://rx.codeplex.com:
|
||||
|
||||
$ cd external
|
||||
$ git clone git://github.com/atsushieno/rx.git
|
||||
$ cd rx
|
||||
$ git checkout rx-oss-v1.0
|
||||
$ cd ../..
|
||||
|
||||
Note that the original repo at rx.codeplex.com will *fail* on Linux!
|
||||
codeplex.codeplex.com/workitem/26133
|
||||
Also note that rx.codeplex.com is huge and takes very long time to checkout.
|
||||
|
||||
- expand rx-mono-changes-3.tar.bz2
|
||||
|
||||
$ tar jxvf rx-mono-changes-3.tar.bz2
|
||||
|
||||
- Apply changes to mcs/class/Makefile:
|
||||
|
||||
$ cd mcs/class
|
||||
$ patch -i add-rx-libs.patch -p3
|
||||
$ cd ../..
|
||||
|
||||
Then it should be done.
|
||||
|
||||
Note that this does not include Mono.Reactive.Testing into the build yet -
|
||||
this library depends on nunit.framework.dll but it wouldn't be built before
|
||||
this assembly is built. This needs to be resolved.
|
||||
|
||||
** Current Status
|
||||
|
||||
- We don't have Microsoft.Reactive.Testing.dll. Instead, I created an
|
||||
alternative Mono.Reactive.Testing.dll which *mostly* uses MS sources for
|
||||
that assembly but uses NUnit.Framework instead.
|
||||
|
||||
To make it happen, I added a small script that automatically replaces
|
||||
MSTest dependency parts with that for NUnit (replacer.sh under rx tree).
|
||||
|
||||
(We'll also have to rename namespaces and have more source changes, but
|
||||
so far it is to get things runnable.)
|
||||
|
||||
- To check the build sanity, I imported unit tests (as explained above)
|
||||
and it is supposed to run by "make run-test" in Mono.Reactive.Testing
|
||||
directory (the tests were all in one place in MS tests, so I made it
|
||||
in Mono.Reactive.Testing directory instead).
|
||||
|
||||
@@ -0,0 +1,16 @@
|
||||
<h1>Mono 1.0 Release Notes</h1>
|
||||
|
||||
<h2>What does Mono Include</h2>
|
||||
|
||||
<h2>Missing functionality</h2>
|
||||
|
||||
<p>COM support.
|
||||
|
||||
<p>EnterpriseServices are non-existant.
|
||||
|
||||
<p>Windows.Forms is only available as a preview, it is not
|
||||
completed nor stable.
|
||||
|
||||
<h3>Assembly: System.Drawing</h3>
|
||||
|
||||
<p>System.Drawing.Printing is not supported.
|
||||
@@ -1,75 +1,33 @@
|
||||
<h2>Assemblies</h2>
|
||||
|
||||
<p>Code in .NET and Mono is distributed in assemblies, there
|
||||
are shipped typically in files with the extension .exe or
|
||||
.dll, and they are files that extend
|
||||
the <a href="https://en.wikipedia.org/wiki/Portable_Executable">Portable
|
||||
Executable</a> file format to include the Common Intermediate
|
||||
Language metadata and portable code.
|
||||
|
||||
<p>Assemblies are typically loaded either from a given file
|
||||
path, or using an <a href="#assembly-name">Assembly Name</a>
|
||||
to load them from the Global Assembly Cache.
|
||||
|
||||
<p>The Mono Assembly API contains method for dealing with
|
||||
<a href="#assembly-name">assembly
|
||||
names</a>, <a href="cil_assembly_load">loading assemblies</a>,
|
||||
<a href="#working">accessing assembly
|
||||
components</a>, <a href="#modules">modules</a> and
|
||||
some <a href="#advanced">advanced</a> features.
|
||||
|
||||
<p>Assemblies contain one or
|
||||
more images, the actual vessels for your code.
|
||||
The <a href="mono-api-image.html">Image API</a> documents the
|
||||
functions that operate on <code>MonoImage *</code>.
|
||||
|
||||
<h3>Synopsis</h3>
|
||||
|
||||
<div class="mapi-header">
|
||||
<div class="header">
|
||||
#include <metadata/assembly.h>
|
||||
|
||||
typedef struct _MonoImage MonoImage;
|
||||
typedef struct _MonoAssembly MonoAssembly;
|
||||
|
||||
@API_IDX@
|
||||
|
||||
</div>
|
||||
|
||||
<a name="cil_assembly_load"/></a>
|
||||
<a name="cil_assembly_load"/>
|
||||
<h3>Assembly Loading</h3>
|
||||
|
||||
<h4><a name="api:mono_assembly_open">mono_assembly_open</a></h4>
|
||||
<h4><a name="api:mono_assembly_close">mono_assembly_close</a></h4>
|
||||
<h4><a name="api:mono_assembly_get_object">mono_assembly_get_object</a></h4>
|
||||
<h4><a name="api:mono_assembly_load">mono_assembly_load</a></h4>
|
||||
<h4><a name="api:mono_assembly_load_full">mono_assembly_load_full</a></h4>
|
||||
<h4><a name="api:mono_assembly_loaded">mono_assembly_loaded</a></h4>
|
||||
<h4><a name="api:mono_assembly_load_from">mono_assembly_load_from</a></h4>
|
||||
<h4><a name="api:mono_assembly_load_from_full">mono_assembly_load_from_full</a></h4>
|
||||
<h4><a name="api:mono_assembly_load_with_partial_name">mono_assembly_load_with_partial_name</a></h4>
|
||||
<h4><a name="api:mono_assembly_open">mono_assembly_open</a></h4>
|
||||
<h4><a name="api:mono_assembly_open_full">mono_assembly_open_full</a></h4>
|
||||
<h4><a name="api:mono_set_assemblies_path">mono_set_assemblies_path</a></h4>
|
||||
<h4><a name="api:mono_set_rootdir">mono_set_rootdir</a></h4>
|
||||
<h4><a name="api:mono_assembly_get_object">mono_assembly_get_object</a></h4>
|
||||
|
||||
<a name="working"/>
|
||||
<h3>Working with Assemblies</h3>
|
||||
|
||||
<h4><a name="api:mono_assembly_fill_assembly_name">mono_assembly_fill_assembly_name</a></h4>
|
||||
<h4><a name="api:mono_assembly_foreach">mono_assembly_foreach</a></h4>
|
||||
<h4><a name="api:mono_assembly_get_image">mono_assembly_get_image</a></h4>
|
||||
<h4><a name="api:mono_assembly_get_main">mono_assembly_get_main</a></h4>
|
||||
<h4><a name="api:mono_assembly_get_name">mono_assembly_get_name</a></h4>
|
||||
<h4><a name="api:mono_assembly_getrootdir">mono_assembly_getrootdir</a></h4>
|
||||
<h4><a name="api:mono_assembly_get_assemblyref">mono_assembly_get_assemblyref</a></h4>
|
||||
<h4><a name="api:mono_assembly_loaded_full">mono_assembly_loaded_full</a></h4>
|
||||
<h4><a name="api:mono_assembly_load_reference">mono_assembly_load_reference</a></h4>
|
||||
<h4><a name="api:mono_assembly_load_references">mono_assembly_load_references</a></h4>
|
||||
<h4><a name="api:mono_assembly_load_module">mono_assembly_load_module</a></h4>
|
||||
<h4><a name="api:mono_assembly_invoke_load_hook">mono_assembly_invoke_load_hook</a></h4>
|
||||
<h4><a name="api:mono_assembly_invoke_search_hook">mono_assembly_invoke_search_hook</a></h4>
|
||||
<h4><a name="api:mono_assembly_set_main">mono_assembly_set_main</a></h4>
|
||||
<h4><a name="api:mono_assembly_setrootdir">mono_assembly_setrootdir</a></h4>
|
||||
<h4><a name="api:mono_register_config_for_assembly">mono_register_config_for_assembly</a></h4>
|
||||
<h4><a name="api:mono_register_symfile_for_assembly">mono_register_symfile_for_assembly</a></h4>
|
||||
|
||||
<a name="assembly-name"></a>
|
||||
<h3>Assembly Names</h3>
|
||||
|
||||
<p>The MonoAssemblyName contains the full identity of an
|
||||
@@ -80,16 +38,10 @@ typedef struct _MonoAssembly MonoAssembly;
|
||||
href="http://www.mono-project.com/monodoc/T:System.Reflection.AssemblyName">System.Reflection.AssemblyName</a>
|
||||
managed type.
|
||||
|
||||
<h4><a name="api:mono_assembly_name_new">mono_assembly_name_new</a></h4>
|
||||
<h4><a name="api:mono_assembly_name_get_name">mono_assembly_name_get_name</a></h4>
|
||||
<h4><a name="api:mono_assembly_name_get_culture">mono_assembly_name_get_culture</a></h4>
|
||||
<h4><a name="api:mono_assembly_name_get_version">mono_assembly_name_get_version</a></h4>
|
||||
<h4><a name="api:mono_assembly_name_get_pubkeytoken">mono_assembly_name_get_pubkeytoken</a></h4>
|
||||
<h4><a name="api:mono_assembly_name_free">mono_assembly_name_free</a></h4>
|
||||
<h4><a name="api:mono_stringify_assembly_name">mono_stringify_assembly_name</a></h4>
|
||||
<h4><a name="api:mono_assembly_names_equal">mono_assembly_names_equal</a></h4>
|
||||
|
||||
<a href="modules"/>
|
||||
<h3>Modules</h3>
|
||||
|
||||
<p>An assembly is made up of one or more modules.
|
||||
@@ -97,14 +49,3 @@ typedef struct _MonoAssembly MonoAssembly;
|
||||
<h4><a name="api:mono_module_file_get_object">mono_module_file_get_object</a></h4>
|
||||
<h4><a name="api:mono_module_get_object">mono_module_get_object</a></h4>
|
||||
|
||||
|
||||
<a href="advanced"/>
|
||||
<h3>Advanced</h3>
|
||||
|
||||
<h4><a name="api:mono_install_assembly_load_hook">mono_install_assembly_load_hook</a></h4>
|
||||
<h4><a name="api:mono_install_assembly_search_hook">mono_install_assembly_search_hook</a></h4>
|
||||
<h4><a name="api:mono_install_assembly_refonly_search_hook">mono_install_assembly_refonly_search_hook</a></h4>
|
||||
<h4><a name="api:mono_install_assembly_preload_hook">mono_install_assembly_preload_hook</a></h4>
|
||||
<h4><a name="api:mono_install_assembly_refonly_preload_hook">mono_install_assembly_refonly_preload_hook</a></h4>
|
||||
<h4><a name="api:mono_install_assembly_postload_search_hook">mono_install_assembly_postload_search_hook</a></h4>
|
||||
<h4><a name="api:mono_install_assembly_postload_refonly_search_hook">mono_install_assembly_postload_refonly_search_hook</a></h4>
|
||||
@@ -1,108 +1,52 @@
|
||||
<h2>Class Operations</h2>
|
||||
|
||||
<p>The operations on <code>MonoClass*</code> allow you to
|
||||
query a number of properties of a .NET class from the C API.
|
||||
|
||||
<p>This page contains information
|
||||
for <a href="#class-getting">how to obtain a MonoClass*</a>,
|
||||
how to <a href="#class-work">probe for different
|
||||
features of a MonoClass*</a> and APIs
|
||||
to <a href="#class-members">access class members</a> and
|
||||
<a href="#class-fields">access fields</a>. To access
|
||||
methods, see the <a href="mono-api-methods.html">method
|
||||
documentation API</a>.
|
||||
|
||||
<a name="class-getting"></a>
|
||||
<h3>Getting a MonoClass</h3>
|
||||
|
||||
<p>You typically would obtain a <code>MonoClass*</code>
|
||||
pointer by using a combination of the <code>MonoImage*</code>
|
||||
where the type is located, the namespace and name using the
|
||||
<code><a href="api:mono_class_from_name">mono_class_from_name</a></code>
|
||||
or
|
||||
the <code><a href="api:mono_class_from_name_case">mono_class_from_name_case</a></code>
|
||||
APIs or by using
|
||||
the <code><a href="api:mono_class_from_typeref">mono_class_from_typeref</a></code>
|
||||
or <code><a href="api:mono_class_from_typeref">mono_class_from_typeref_checked</a></code>
|
||||
methods.
|
||||
|
||||
<p>For low-level access, you can get the <code>MonoClass
|
||||
*</code> from an image and an ECMA type token relative to
|
||||
the <code>MonoImage*</code> by using <a href="api:mono_class_get">mono_class_get</a>.
|
||||
|
||||
|
||||
<h4><a name="api:mono_class_get">mono_class_get</a></h4>
|
||||
<h4><a name="api:mono_class_from_mono_type">mono_class_from_mono_type</a></h4>
|
||||
<h4><a name="api:mono_class_from_name">mono_class_from_name</a></h4>
|
||||
<h4><a name="api:mono_class_from_name_case">mono_class_from_name_case</a></h4>
|
||||
<h4><a name="api:mono_class_from_typeref">mono_class_from_typeref</a></h4>
|
||||
<h4><a name="api:mono_class_from_typeref_checked">mono_class_from_typeref_checked</a></h4>
|
||||
<h4><a name="api:mono_class_from_generic_parameter">mono_class_from_generic_parameter</a></h4>
|
||||
|
||||
<h3>Working with a MonoClass</h3>
|
||||
|
||||
<h4><a name="api:mono_class_array_element_size">mono_class_array_element_size</a></h4>
|
||||
<h4><a name="api:mono_class_data_size">mono_class_data_size</a></h4>
|
||||
<h4><a name="api:mono_class_enum_basetype">mono_class_enum_basetype</a></h4>
|
||||
<h4><a name="api:mono_class_from_generic_parameter">mono_class_from_generic_parameter</a></h4>
|
||||
<h4><a name="api:mono_class_from_mono_type">mono_class_from_mono_type</a></h4>
|
||||
<h4><a name="api:mono_class_from_name_case">mono_class_from_name_case</a></h4>
|
||||
<h4><a name="api:mono_class_from_name">mono_class_from_name</a></h4>
|
||||
<h4><a name="api:mono_class_from_typeref">mono_class_from_typeref</a></h4>
|
||||
<h4><a name="api:mono_class_get_byref_type">mono_class_get_byref_type</a></h4>
|
||||
<h4><a name="api:mono_class_get_element_class">mono_class_get_element_class</a></h4>
|
||||
<h4><a name="api:mono_class_get_events">mono_class_get_events</a></h4>
|
||||
<h4><a name="api:mono_class_get_event_token">mono_class_get_event_token</a></h4>
|
||||
<h4><a name="api:mono_class_get_field_from_name">mono_class_get_field_from_name</a></h4>
|
||||
<h4><a name="api:mono_class_get_field">mono_class_get_field</a></h4>
|
||||
<h4><a name="api:mono_class_get_fields">mono_class_get_fields</a></h4>
|
||||
<h4><a name="api:mono_class_get_field_token">mono_class_get_field_token</a></h4>
|
||||
<h4><a name="api:mono_class_get_flags">mono_class_get_flags</a></h4>
|
||||
<h4><a name="api:mono_class_get_full">mono_class_get_full</a></h4>
|
||||
<h4><a name="api:mono_class_get_image">mono_class_get_image</a></h4>
|
||||
<h4><a name="api:mono_class_get_interfaces">mono_class_get_interfaces</a></h4>
|
||||
<h4><a name="api:mono_class_get_method_from_name">mono_class_get_method_from_name</a></h4>
|
||||
<h4><a name="api:mono_class_get_methods">mono_class_get_methods</a></h4>
|
||||
<h4><a name="api:mono_class_get">mono_class_get</a></h4>
|
||||
<h4><a name="api:mono_class_get_name">mono_class_get_name</a></h4>
|
||||
<h4><a name="api:mono_class_get_namespace">mono_class_get_namespace</a></h4>
|
||||
<h4><a name="api:mono_class_get_nested_types">mono_class_get_nested_types</a></h4>
|
||||
<h4><a name="api:mono_class_get_nesting_type">mono_class_get_nesting_type</a></h4>
|
||||
<h4><a name="api:mono_class_get_parent">mono_class_get_parent</a></h4>
|
||||
<h4><a name="api:mono_class_get_properties">mono_class_get_properties</a></h4>
|
||||
<h4><a name="api:mono_class_get_property_from_name">mono_class_get_property_from_name</a></h4>
|
||||
<h4><a name="api:mono_class_get_property_token">mono_class_get_property_token</a></h4>
|
||||
<h4><a name="api:mono_class_get_rank">mono_class_get_rank</a></h4>
|
||||
<h4><a name="api:mono_class_get_type">mono_class_get_type</a></h4>
|
||||
<h4><a name="api:mono_class_get_type_token">mono_class_get_type_token</a></h4>
|
||||
<h4><a name="api:mono_class_implements_interface">mono_class_implements_interface</a></h4>
|
||||
<h4><a name="api:mono_class_inflate_generic_method">mono_class_inflate_generic_method</a></h4>
|
||||
<h4><a name="api:mono_class_inflate_generic_type">mono_class_inflate_generic_type</a></h4>
|
||||
<h4><a name="api:mono_class_init">mono_class_init</a></h4>
|
||||
<h4><a name="api:mono_class_instance_size">mono_class_instance_size</a></h4>
|
||||
<h4><a name="api:mono_class_is_assignable_from">mono_class_is_assignable_from</a></h4>
|
||||
<h4><a name="api:mono_class_is_delegate">mono_class_is_delegate</a></h4>
|
||||
<h4><a name="api:mono_class_is_enum">mono_class_is_enum</a></h4>
|
||||
<h4><a name="api:mono_class_is_subclass_of">mono_class_is_subclass_of</a></h4>
|
||||
<h4><a name="api:mono_class_is_valuetype">mono_class_is_valuetype</a></h4>
|
||||
<h4><a name="api:mono_class_min_align">mono_class_min_align</a></h4>
|
||||
<h4><a name="api:mono_class_name_from_token">mono_class_name_from_token</a></h4>
|
||||
<h4><a name="api:mono_class_num_events">mono_class_num_events</a></h4>
|
||||
<h4><a name="api:mono_class_num_fields">mono_class_num_fields</a></h4>
|
||||
<h4><a name="api:mono_class_num_methods">mono_class_num_methods</a></h4>
|
||||
<h4><a name="api:mono_class_num_properties">mono_class_num_properties</a></h4>
|
||||
<h4><a name="api:mono_class_value_size">mono_class_value_size</a></h4>
|
||||
<h4><a name="api:mono_class_vtable">mono_class_vtable</a></h4>
|
||||
|
||||
<a name="class-members"></a>
|
||||
<h3>Getting Class Members</h3>
|
||||
|
||||
<h4><a name="api:mono_class_get_fields">mono_class_get_fields</a></h4>
|
||||
<h4><a name="api:mono_class_get_field_from_name">mono_class_get_field_from_name</a></h4>
|
||||
<h4><a name="api:mono_class_get_methods">mono_class_get_methods</a></h4>
|
||||
<h4><a name="api:mono_class_get_method_from_name">mono_class_get_method_from_name</a></h4>
|
||||
<h4><a name="api:mono_class_get_method_from_name_flags">mono_class_get_method_from_name_flags</a></h4>
|
||||
<h4><a name="api:mono_class_get_nested_types">mono_class_get_nested_types</a></h4>
|
||||
<h4><a name="api:mono_class_get_properties">mono_class_get_properties</a></h4>
|
||||
<h4><a name="api:mono_class_get_property_from_name">mono_class_get_property_from_name</a></h4>
|
||||
<h4><a name="api:mono_class_get_events">mono_class_get_events</a></h4>
|
||||
|
||||
<a name="class-fields"></a>
|
||||
<h3>Fields</h3>
|
||||
|
||||
<h4><a name="api:mono_field_get_data">mono_field_get_data</a></h4>
|
||||
<h4><a name="api:mono_field_get_offset">mono_field_get_offset</a></h4>
|
||||
<h4><a name="api:mono_field_full_name">mono_field_full_name</a></h4>
|
||||
|
||||
<h3>Method Accessibility</h3>
|
||||
|
||||
<h4><a name="api:mono_method_can_access_field">mono_method_can_access_field</a></h4>
|
||||
<h4><a name="api:mono_method_can_access_method">mono_method_can_access_method</a></h4>
|
||||
|
||||
<p>
|
||||
<h4><a name="api:mono_class_name_from_token">mono_class_name_from_token</a></h4>
|
||||
@@ -0,0 +1,10 @@
|
||||
<h3>Code manager</h3>
|
||||
|
||||
<h4><a name="api:mono_code_manager_commit">mono_code_manager_commit</a></h4>
|
||||
<h4><a name="api:mono_code_manager_destroy">mono_code_manager_destroy</a></h4>
|
||||
<h4><a name="api:mono_code_manager_foreach">mono_code_manager_foreach</a></h4>
|
||||
<h4><a name="api:mono_code_manager_invalidate">mono_code_manager_invalidate</a></h4>
|
||||
<h4><a name="api:mono_code_manager_new_dynamic">mono_code_manager_new_dynamic</a></h4>
|
||||
<h4><a name="api:mono_code_manager_new">mono_code_manager_new</a></h4>
|
||||
<h4><a name="api:mono_code_manager_reserve">mono_code_manager_reserve</a></h4>
|
||||
|
||||
@@ -1,38 +1,23 @@
|
||||
<h4><a name="api:mono_debug_il_offset_from_address">mono_debug_il_offset_from_address</a></h4>
|
||||
<h4><a name="api:mono_debug_add_method">mono_debug_add_method</a></h4>
|
||||
<h4><a name="api:mono_debug_close_mono_symbol_file">mono_debug_close_mono_symbol_file</a></h4>
|
||||
<h4><a name="api:mono_debug_find_method">mono_debug_find_method</a></h4>
|
||||
<h4><a name="api:mono_debug_using_mono_debugger">mono_debug_using_mono_debugger</a></h4>
|
||||
|
||||
<h3>Mono Debugger Interface</h3>
|
||||
|
||||
<p>These are methods that are invoked by the debugger at
|
||||
runtime.
|
||||
|
||||
<h4><a name="api:mono_debugger_breakpoint_callback">mono_debugger_breakpoint_callback</a></h4>
|
||||
<h4><a name="api:mono_debugger_check_runtime_version">mono_debugger_check_runtime_version</a></h4>
|
||||
<h4><a name="api:mono_debugger_event">mono_debugger_event</a></h4>
|
||||
<h4><a name="api:mono_debugger_handle_exception">mono_debugger_handle_exception</a></h4>
|
||||
<h4><a name="api:mono_debugger_insert_breakpoint_full">mono_debugger_insert_breakpoint_full</a></h4>
|
||||
<h4><a name="api:mono_debugger_insert_breakpoint">mono_debugger_insert_breakpoint</a></h4>
|
||||
<h4><a name="api:mono_debugger_lock">mono_debugger_lock</a></h4>
|
||||
<h4><a name="api:mono_debugger_method_has_breakpoint">mono_debugger_method_has_breakpoint</a></h4>
|
||||
|
||||
<h3>Debugging Symbols</h3>
|
||||
<h4><a name="api:mono_debug_open_mono_symbols">mono_debug_open_mono_symbols</a></h4>
|
||||
<h4><a name="api:mono_debug_symfile_free_location">mono_debug_symfile_free_location</a></h4>
|
||||
<h4><a name="api:mono_debug_symfile_is_loaded">mono_debug_symfile_is_loaded</a></h4>
|
||||
<h4><a name="api:mono_debug_symfile_lookup_locals">mono_debug_symfile_lookup_locals</a></h4>
|
||||
<h4><a name="api:mono_debug_symfile_lookup_location">mono_debug_symfile_lookup_location</a></h4>
|
||||
<h4><a name="api:mono_debug_symfile_lookup_method">mono_debug_symfile_lookup_method</a></h4>
|
||||
|
||||
<h3>Internal Debugging </h3>
|
||||
|
||||
<h4><a name="api:mono_debug_add_delegate_trampoline">mono_debug_add_delegate_trampoline</a></h4>
|
||||
<h4><a name="api:mono_debug_close_image">mono_debug_close_image</a></h4>
|
||||
<h4><a name="api:mono_debug_domain_create">mono_debug_domain_create</a></h4>
|
||||
<h4><a name="api:mono_debug_domain_unload">mono_debug_domain_unload</a></h4>
|
||||
<h4><a name="api:mono_debug_enabled">mono_debug_enabled</a></h4>
|
||||
<h4><a name="api:mono_debug_free_method_jit_info">mono_debug_free_method_jit_info</a></h4>
|
||||
<h4><a name="api:mono_debug_free_source_location">mono_debug_free_source_location</a></h4>
|
||||
<h4><a name="api:mono_debug_lookup_locals">mono_debug_lookup_locals</a></h4>
|
||||
<h4><a name="api:mono_debug_lookup_method">mono_debug_lookup_method</a></h4>
|
||||
<h4><a name="api:mono_debug_lookup_method_addresses">mono_debug_lookup_method_addresses</a></h4>
|
||||
<h4><a name="api:mono_debug_lookup_source_location">mono_debug_lookup_source_location</a></h4>
|
||||
<h4><a name="api:mono_debug_open_image_from_memory">mono_debug_open_image_from_memory</a></h4>
|
||||
<h4><a name="api:mono_debug_print_stack_frame">mono_debug_print_stack_frame</a></h4>
|
||||
<h4><a name="api:mono_debug_remove_method">mono_debug_remove_method</a></h4>
|
||||
<h4><a name="api:mono_debug_il_offset_from_address">mono_debug_il_offset_from_address</a></h4>
|
||||
<h4><a name="api:mono_debug_add_method">mono_debug_add_method</a></h4>
|
||||
<h4><a name="api:mono_debug_close_mono_symbol_file">mono_debug_close_mono_symbol_file</a></h4>
|
||||
<h4><a name="api:mono_debug_find_method">mono_debug_find_method</a></h4>
|
||||
|
||||
<h4><a name="api:mono_debugger_remove_breakpoint">mono_debugger_remove_breakpoint</a></h4>
|
||||
<h4><a name="api:mono_debugger_runtime_invoke">mono_debugger_runtime_invoke</a></h4>
|
||||
<h4><a name="api:mono_debugger_unlock">mono_debugger_unlock</a></h4>
|
||||
<h4><a name="api:mono_debugger_run_finally">mono_debugger_run_finally</a></h4>
|
||||
@@ -0,0 +1,19 @@
|
||||
<h1>Decimal Support</h1>
|
||||
|
||||
<p>You can use the mono_decimal functions to access and
|
||||
manipulate <tt>System.Decimal</tt> types from C.
|
||||
|
||||
<h4><a name="api:mono_decimal2double">mono_decimal2double</a></h4>
|
||||
<h4><a name="api:mono_decimal2Int64">mono_decimal2Int64</a></h4>
|
||||
<h4><a name="api:mono_decimal2string">mono_decimal2string</a></h4>
|
||||
<h4><a name="api:mono_decimal2UInt64">mono_decimal2UInt64</a></h4>
|
||||
<h4><a name="api:mono_decimalCompare">mono_decimalCompare</a></h4>
|
||||
<h4><a name="api:mono_decimalDiv">mono_decimalDiv</a></h4>
|
||||
<h4><a name="api:mono_decimalFloorAndTrunc">mono_decimalFloorAndTrunc</a></h4>
|
||||
<h4><a name="api:mono_decimalIncr">mono_decimalIncr</a></h4>
|
||||
<h4><a name="api:mono_decimalIntDiv">mono_decimalIntDiv</a></h4>
|
||||
<h4><a name="api:mono_decimalMult">mono_decimalMult</a></h4>
|
||||
<h4><a name="api:mono_decimalRound">mono_decimalRound</a></h4>
|
||||
<h4><a name="api:mono_decimalSetExponent">mono_decimalSetExponent</a></h4>
|
||||
<h4><a name="api:mono_double2decimal">mono_double2decimal</a></h4>
|
||||
<h4><a name="api:mono_string2decimal">mono_string2decimal</a></h4>
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<h3>Synopsis</h3>
|
||||
|
||||
<div class="mapi-header">
|
||||
<div class="header">
|
||||
#include <metadata/appdomain.h>
|
||||
|
||||
/* Managed AppDomain */
|
||||
@@ -34,30 +34,21 @@ typedef struct _MonoAppContext MonoAppContext
|
||||
|
||||
<h4><a name="api:mono_domain_assembly_open">mono_domain_assembly_open</a></h4>
|
||||
<h4><a name="api:mono_domain_create">mono_domain_create</a></h4>
|
||||
<h4><a name="api:mono_domain_create_appdomain">mono_domain_create_appdomain</a></h4>
|
||||
<h4><a name="api:mono_domain_finalize">mono_domain_finalize</a></h4>
|
||||
<h4><a name="api:mono_domain_foreach">mono_domain_foreach</a></h4>
|
||||
<h4><a name="api:mono_domain_free">mono_domain_free</a></h4>
|
||||
<h4><a name="api:mono_domain_from_appdomain">mono_domain_from_appdomain</a></h4>
|
||||
<h4><a name="api:mono_domain_get_by_id">mono_domain_get_by_id</a></h4>
|
||||
<h4><a name="api:mono_domain_get_friendly_name">mono_domain_get_friendly_name</a></h4>
|
||||
<h4><a name="api:mono_domain_get_id">mono_domain_get_id</a></h4>
|
||||
<h4><a name="api:mono_domain_get">mono_domain_get</a></h4>
|
||||
<h4><a name="api:mono_domain_has_type_resolve">mono_domain_has_type_resolve</a></h4>
|
||||
<h4><a name="api:mono_domain_is_unloading">mono_domain_is_unloading</a></h4>
|
||||
<h4><a name="api:mono_domain_owns_vtable_slot">mono_domain_owns_vtable_slot</a></h4>
|
||||
<h4><a name="api:mono_domain_set_config">mono_domain_set_config</a></h4>
|
||||
<h4><a name="api:mono_domain_set_internal">mono_domain_set_internal</a></h4>
|
||||
<h4><a name="api:mono_domain_set">mono_domain_set</a></h4>
|
||||
<h4><a name="api:mono_domain_try_type_resolve">mono_domain_try_type_resolve</a></h4>
|
||||
<h4><a name="api:mono_domain_try_unload">mono_domain_try_unload</a></h4>
|
||||
<h4><a name="api:mono_domain_unload">mono_domain_unload</a></h4>
|
||||
<h4><a name="api:mono_domain_owns_vtable_slot">mono_domain_owns_vtable_slot</a></h4>
|
||||
|
||||
<h3>Contexts</h3>
|
||||
|
||||
<h4><a name="api:mono_context_init">mono_context_init</a></h4>
|
||||
<h4><a name="api:mono_context_get">mono_context_get</a></h4>
|
||||
<h4><a name="api:mono_context_get_domain_id">mono_context_get_domain_id</a></h4>
|
||||
<h4><a name="api:mono_context_get_id">mono_context_get_id</a></h4>
|
||||
<h4><a name="api:mono_context_set">mono_context_set</a></h4>
|
||||
<h4><a name="api:mono_context_get_desc">mono_context_get_desc</a></h4>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<h2>Internal: Dynamic Code Generation</h2>
|
||||
<h2>Dynamic Code Generation</h2>
|
||||
|
||||
<p>The dynamic code generation interface inside the Mono
|
||||
runtime is similar to the API exposed by
|
||||
|
||||
@@ -1,18 +1,5 @@
|
||||
<h2>Embedding Mono</h2>
|
||||
|
||||
<p>The Mono runtime can be embedded into C and C++
|
||||
applications. Your C/C++ code can invoke managed code
|
||||
running in the Mono/.NET world and you can also surface your
|
||||
internal application APIs to Mono and .NET.
|
||||
|
||||
<p>For an overview of how to embed Mono into your application
|
||||
and the strategies that you can use to embed Mono, check the
|
||||
Mono
|
||||
website's <a href="http://www.mono-project.com/docs/advanced/embedding/">Embedding
|
||||
Mono</a> page.
|
||||
|
||||
<p>This page is the companion API reference for the above guide.
|
||||
|
||||
<p>The simplest way of embedding Mono is illustrated here:
|
||||
<pre>
|
||||
int main (int argc, char *argv)
|
||||
@@ -61,14 +48,13 @@ getMessage ()
|
||||
</pre>
|
||||
|
||||
<h4><a name="api:mono_jit_init">mono_jit_init</a></h4>
|
||||
<h4><a name="api:mono_jit_parse_options">mono_jit_parse_options</a></h4>
|
||||
<h4><a name="api:mono_jit_exec">mono_jit_exec</a></h4>
|
||||
<h4><a name="api:mono_set_dirs">mono_set_dirs</a></h4>
|
||||
<h4><a name="api:mono_main">mono_main</a></h4>
|
||||
<h4><a name="api:mono_parse_default_optimizations">mono_parse_default_optimizations</a></h4>
|
||||
<h4><a name="api:mono_runtime_set_main_args">mono_runtime_set_main_args</a></h4>
|
||||
<h4><a name="api:mono_jit_cleanup">mono_jit_cleanup</a></h4>
|
||||
<h4><a name="api:mono_jit_set_trace_options">mono_jit_set_trace_options</a></h4>
|
||||
|
||||
<h4><a name="api:mono_jit_cleanup">mono_jit_cleanup</a></h4>
|
||||
<h4><a name="api:mono_set_defaults">mono_set_defaults</a></h4>
|
||||
|
||||
<h3>Internal Calls</h3>
|
||||
|
||||
@@ -155,16 +141,19 @@ getMessage ()
|
||||
|
||||
<p>The following APIs expose this functionality:
|
||||
|
||||
<h4><a name="api:mono_config_cleanup">mono_config_cleanup</a></h4>
|
||||
<h4><a name="api:mono_config_is_server_mode">mono_config_is_server_mode</a></h4>
|
||||
<h4><a name="api:mono_config_parse">mono_config_parse</a></h4>
|
||||
<h4><a name="api:mono_config_parse_memory">mono_config_parse_memory</a></h4>
|
||||
<h4><a name="api:mono_config_set_server_mode">mono_config_set_server_mode</a></h4>
|
||||
<h4><a name="api:mono_config_string_for_assembly_file">mono_config_string_for_assembly_file</a></h4>
|
||||
<h4><a name="api:mono_get_config_dir">mono_get_config_dir</a></h4>
|
||||
<h4><a name="api:mono_get_machine_config">mono_get_machine_config</a></h4>
|
||||
<h4><a name="api:mono_register_machine_config">mono_register_machine_config</a></h4>
|
||||
<h4><a name="api:mono_set_config_dir">mono_set_config_dir</a></h4>
|
||||
|
||||
<h3>Function Pointers</h3>
|
||||
|
||||
<p>To wrap a function pointer into something that the Mono
|
||||
runtime can consume, you should use the mono_create_ftnptr.
|
||||
This is only important if you plan on running on the IA64
|
||||
architecture. Otherwise you can just use the function
|
||||
pointer address.
|
||||
|
||||
<h4><a name="api:mono_create_ftnptr">mono_create_ftnptr</a></h4>
|
||||
|
||||
<h3>Advanced Execution Setups</h3>
|
||||
|
||||
@@ -174,15 +163,6 @@ getMessage ()
|
||||
|
||||
<h4><a name="api:mono_runtime_exec_managed_code">mono_runtime_exec_managed_code</a></h4>
|
||||
<h4><a name="api:mono_runtime_exec_main">mono_runtime_exec_main</a></h4>
|
||||
<h4><a name="api:mono_init">mono_init</a></h4>
|
||||
<h4><a name="api:mono_init_from_assembly">mono_init_from_assembly</a></h4>
|
||||
<h4><a name="api:mono_init">mono_init</a></h4>
|
||||
<h4><a name="api:mono_init_version">mono_init_version</a></h4>
|
||||
<h4><a name="api:mono_jit_exec">mono_jit_exec</a></h4>
|
||||
<h4><a name="api:mono_jit_set_aot_mode">mono_jit_set_aot_mode</a></h4>
|
||||
<h4><a name="api:mono_set_break_policy">mono_set_break_policy</a></h4>
|
||||
<h4><a name="api:mono_get_runtime_build_info">mono_get_runtime_build_info</a></h4>
|
||||
|
||||
<h3>Signal Chaining</h3>
|
||||
|
||||
<h4><a name="api:mono_set_signal_chaining">mono_set_signal_chaining</a></h4>
|
||||
<h4><a name="api:mono_set_crash_chaining">mono_set_crash_chaining</a></h4>
|
||||
@@ -1,32 +1,16 @@
|
||||
<h2>Exception Handling</h2>
|
||||
|
||||
<p>Mono's exception handling contains methods
|
||||
to <a href="#creating">create `MonoException*` objects</a>
|
||||
that can be <a href="api:mono_raise_exception">raised</a>.
|
||||
<div class="header">
|
||||
@API_IDX@
|
||||
</div>
|
||||
|
||||
<p>Alternatively, you can obtain an exception that you can
|
||||
raise from some of the most <a href="#common">common</a>
|
||||
exceptions in the .NET Runtime.
|
||||
|
||||
<h3>Raising and Catching exceptions</h3>
|
||||
|
||||
<p>If you plan on running your code in Mono's Cooperative mode
|
||||
for the Garbage Collector (for example, if you are using pure
|
||||
Bitcode code generation), it you should avoid raising an
|
||||
exception from any method that is not the entry point to the
|
||||
internal call.
|
||||
|
||||
<p>It is recommended that if you need to raise an error
|
||||
condition from nested parts of your code, surface this error
|
||||
to the topmost method that is surfaced as an internal call and
|
||||
raise the exception there.
|
||||
|
||||
|
||||
<h4><a name="api:mono_raise_exception">mono_raise_exception</a></h4>
|
||||
<h4><a name="api:mono_unhandled_exception">mono_unhandled_exception</a></h4>
|
||||
<h4><a name="api:mono_print_unhandled_exception">mono_print_unhandled_exception</a></h4>
|
||||
|
||||
<a name="creating"/>
|
||||
|
||||
<h3>Exception Types: General API</h3>
|
||||
|
||||
<h4><a name="api:mono_exception_from_name_domain">mono_exception_from_name_domain</a></h4>
|
||||
@@ -34,7 +18,6 @@
|
||||
<h4><a name="api:mono_exception_from_name_msg">mono_exception_from_name_msg</a></h4>
|
||||
<h4><a name="api:mono_exception_from_name_two_strings">mono_exception_from_name_two_strings</a></h4>
|
||||
|
||||
<a name="common"/>
|
||||
<h3>Obtaining Common Exceptions</h3>
|
||||
|
||||
<p>There are a number of common exceptions that are used by
|
||||
@@ -73,10 +56,3 @@
|
||||
<h4><a name="api:mono_get_exception_missing_field">mono_get_exception_missing_field</a></h4>
|
||||
<h4><a name="api:mono_get_exception_not_supported">mono_get_exception_not_supported</a></h4>
|
||||
<h4><a name="api:mono_get_exception_reflection_type_load">mono_get_exception_reflection_type_load</a></h4>
|
||||
<h4><a name="api:mono_exception_from_token_two_strings">mono_exception_from_token_two_strings</a></h4>
|
||||
<h4><a name="api:mono_get_exception_bad_image_format2">mono_get_exception_bad_image_format2</a></h4>
|
||||
<h4><a name="api:mono_get_exception_field_access">mono_get_exception_field_access</a></h4>
|
||||
<h4><a name="api:mono_get_exception_method_access">mono_get_exception_method_access</a></h4>
|
||||
<h4><a name="api:mono_get_exception_out_of_memory">mono_get_exception_out_of_memory</a></h4>
|
||||
<h4><a name="api:mono_get_exception_runtime_wrapped">mono_get_exception_runtime_wrapped</a></h4>
|
||||
<h4><a name="api:mono_get_exception_thread_interrupted">mono_get_exception_thread_interrupted</a></h4>
|
||||
@@ -4,118 +4,9 @@
|
||||
|
||||
<p>The public interface of the Mono GC is fairly limited, and
|
||||
its the only one that embedders should be using:
|
||||
|
||||
<h3>Garbage Collector</h3>
|
||||
|
||||
|
||||
<h4><a name="api:mono_gc_collect">mono_gc_collect</a></h4>
|
||||
<h4><a name="api:mono_gc_collection_count">mono_gc_collection_count</a></h4>
|
||||
<h4><a name="api:mono_gc_max_generation">mono_gc_max_generation</a></h4>
|
||||
<h4><a name="api:mono_gc_get_generation">mono_gc_get_generation</a></h4>
|
||||
<h4><a name="api:mono_gc_get_heap_size">mono_gc_get_heap_size</a></h4>
|
||||
<h4><a name="api:mono_gc_get_used_size">mono_gc_get_used_size</a></h4>
|
||||
<h4><a name="api:mono_gc_walk_heap">mono_gc_walk_heap</a></h4>
|
||||
|
||||
<h3>Reference Queues</h3>
|
||||
|
||||
<h4><a name="api:mono_gc_reference_queue_add">mono_gc_reference_queue_add</a></h4>
|
||||
<h4><a name="api:mono_gc_reference_queue_free">mono_gc_reference_queue_free</a></h4>
|
||||
<h4><a name="api:mono_gc_reference_queue_new">mono_gc_reference_queue_new</a></h4>
|
||||
|
||||
<h3>SGen Bridge</h3>
|
||||
|
||||
<p>The bridge is a mechanism for SGen to let clients override
|
||||
the death of some unreachable objects. We use it in monodroid
|
||||
to do garbage collection across the Mono and Java heaps.
|
||||
|
||||
<p>The client can designate some objects as "bridged", which
|
||||
means that they participate in the bridge processing step once
|
||||
SGen considers them unreachable, i.e., dead. Bridged objects
|
||||
must be registered for finalization.
|
||||
|
||||
<p>When SGen is done marking, it puts together a list of all
|
||||
dead bridged objects and then does a strongly connected
|
||||
component analysis over their object graph. That graph will
|
||||
usually contain non-bridged objects, too.
|
||||
|
||||
<p>The output of the SCC analysis is passed to the
|
||||
`cross_references()` callback. It is expected to set the
|
||||
`is_alive` flag on those strongly connected components that it
|
||||
wishes to be kept alive. Only bridged objects will be
|
||||
reported to the callback, i.e., non-bridged objects are
|
||||
removed from the callback graph.
|
||||
|
||||
<p>In monodroid each bridged object has a corresponding Java
|
||||
mirror object. In the bridge callback it reifies the Mono
|
||||
object graph in the Java heap so that the full, combined
|
||||
object graph is now instantiated on the Java side. Then it
|
||||
triggers a Java GC, waits for it to finish, and checks which
|
||||
of the Java mirror objects are still alive. For those it sets
|
||||
the `is_alive` flag and returns from the callback.
|
||||
|
||||
<p>The SCC analysis is done while the world is stopped, but
|
||||
the callback is made with the world running again. Weak links
|
||||
to bridged objects and other objects reachable from them are
|
||||
kept until the callback returns, at which point all links to
|
||||
bridged objects that don't have `is_alive` set are nulled.
|
||||
Note that weak links to non-bridged objects reachable from
|
||||
bridged objects are not nulled. This might be considered a
|
||||
bug.
|
||||
|
||||
<div class="mapi-header">
|
||||
enum {
|
||||
SGEN_BRIDGE_VERSION = 4
|
||||
};
|
||||
|
||||
typedef enum {
|
||||
/* Instances of this class should be scanned when computing the transitive dependency among bridges. E.g. List of object*/
|
||||
GC_BRIDGE_TRANSPARENT_CLASS,
|
||||
/* Instances of this class should not be scanned when computing the transitive dependency among bridges. E.g. String*/
|
||||
GC_BRIDGE_OPAQUE_CLASS,
|
||||
/* Instances of this class should be bridged and have their dependency computed. */
|
||||
GC_BRIDGE_TRANSPARENT_BRIDGE_CLASS,
|
||||
/* Instances of this class should be bridged but no dependencies should not be calculated. */
|
||||
GC_BRIDGE_OPAQUE_BRIDGE_CLASS,
|
||||
} MonoGCBridgeObjectKind;
|
||||
|
||||
typedef struct {
|
||||
mono_bool is_alive; /* to be set by the cross reference callback */
|
||||
int num_objs;
|
||||
MonoObject *objs [MONO_ZERO_LEN_ARRAY];
|
||||
} MonoGCBridgeSCC;
|
||||
|
||||
typedef struct {
|
||||
int src_scc_index;
|
||||
int dst_scc_index;
|
||||
} MonoGCBridgeXRef;
|
||||
|
||||
typedef struct {
|
||||
int bridge_version;
|
||||
/*
|
||||
* Tells the runtime which classes to even consider when looking for
|
||||
* bridged objects. If subclasses are to be considered as well, the
|
||||
* subclass check must be done in the callback.
|
||||
*/
|
||||
MonoGCBridgeObjectKind (*bridge_class_kind) (MonoClass *klass);
|
||||
/*
|
||||
* This is only called on objects for whose classes
|
||||
* `bridge_class_kind()` returned `XXX_BRIDGE_CLASS`.
|
||||
*/
|
||||
mono_bool (*is_bridge_object) (MonoObject *object);
|
||||
void (*cross_references) (int num_sccs, MonoGCBridgeSCC **sccs, int num_xrefs, MonoGCBridgeXRef *xrefs);
|
||||
} MonoGCBridgeCallbacks;
|
||||
</div>
|
||||
|
||||
<h4><a name="api:mono_gc_register_bridge_callbacks">mono_gc_register_bridge_callbacks</a></h4>
|
||||
<h4><a name="api:mono_gc_wait_for_bridge_processing">mono_gc_wait_for_bridge_processing</a></h4>
|
||||
|
||||
<h3>Write Barriers</h3>
|
||||
|
||||
<h4><a name="api:mono_gc_wbarrier_arrayref_copy">mono_gc_wbarrier_arrayref_copy</a></h4>
|
||||
<h4><a name="api:mono_gc_wbarrier_generic_nostore">mono_gc_wbarrier_generic_nostore</a></h4>
|
||||
<h4><a name="api:mono_gc_wbarrier_generic_store">mono_gc_wbarrier_generic_store</a></h4>
|
||||
<h4><a name="api:mono_gc_wbarrier_generic_store_atomic">mono_gc_wbarrier_generic_store_atomic</a></h4>
|
||||
<h4><a name="api:mono_gc_wbarrier_object_copy">mono_gc_wbarrier_object_copy</a></h4>
|
||||
<h4><a name="api:mono_gc_wbarrier_set_arrayref">mono_gc_wbarrier_set_arrayref</a></h4>
|
||||
<h4><a name="api:mono_gc_wbarrier_set_field">mono_gc_wbarrier_set_field</a></h4>
|
||||
<h4><a name="api:mono_gc_wbarrier_value_copy">mono_gc_wbarrier_value_copy</a></h4>
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<h3>Synopsys</h3>
|
||||
|
||||
<div class="mapi-header">
|
||||
<div class="header">
|
||||
@API_IDX@
|
||||
</div>
|
||||
|
||||
@@ -31,8 +31,7 @@
|
||||
<tt>mono_gchandle_get_target</tt>.
|
||||
|
||||
<p>For example, consider the following C code:
|
||||
|
||||
<div class="mapi-code">
|
||||
<div class="code">
|
||||
static MonoObject* o = NULL;
|
||||
</div>
|
||||
|
||||
@@ -42,22 +41,22 @@ static MonoObject* o = NULL;
|
||||
it from being collected, you need to acquire a GC handle for
|
||||
it.
|
||||
|
||||
<div class="mapi-code">
|
||||
guint32 handle = mono_gchandle_new (my_object, TRUE);
|
||||
<div class="code">
|
||||
guint32 handle = mono_gchandle_new (my_object, TRUE);
|
||||
</div>
|
||||
|
||||
<p>TRUE means the object will be pinned, so it won't move in
|
||||
memory when we'll use a moving GC. You can access the
|
||||
MonoObject* referenced by a handle with:
|
||||
|
||||
<div class="mapi-code">
|
||||
MonoObject* obj = mono_gchandle_get_target (handle);
|
||||
<div class="code">
|
||||
MonoObject* obj = mono_gchandle_get_target (handle);
|
||||
</div>
|
||||
|
||||
<p>When you don't need the handle anymore you need to call:
|
||||
|
||||
<div class="mapi-code">
|
||||
mono_gchandle_free (handle);
|
||||
<div class="code">
|
||||
mono_gchandle_free (handle);
|
||||
</div>
|
||||
|
||||
<p>Note that if you assign a new object to the C var, you need
|
||||
@@ -66,27 +65,27 @@ mono_gchandle_free (handle);
|
||||
|
||||
<p>So code that looked like this:
|
||||
|
||||
<div class="mapi-code">
|
||||
static MonoObject* obj = NULL;
|
||||
...
|
||||
obj = mono_object_new (...);
|
||||
// use obj
|
||||
...
|
||||
// when done to allow the GC to collect obj
|
||||
obj = NULL;
|
||||
<div class="code">
|
||||
static MonoObject* o = NULL;
|
||||
...
|
||||
o = mono_object_new (...);
|
||||
/* use o */
|
||||
...
|
||||
/* when done to allow the GC to collect o */
|
||||
o = NULL;
|
||||
</div>
|
||||
|
||||
<p>should now be changed to:
|
||||
|
||||
<div class="mapi-code">
|
||||
static guint32 o_handle;
|
||||
...
|
||||
MonoObject *obj = mono_object_new (...);
|
||||
o_handle = mono_gchandle_new (obj, TRUE);
|
||||
// use o or mono_gchandle_get_target (o_handle)
|
||||
...
|
||||
// when done to allow the GC to collect obj
|
||||
mono_gchandle_free (o_handle);
|
||||
<div class="code">
|
||||
static guint32 o_handle;
|
||||
...
|
||||
MonoObject *o = mono_object_new (...);
|
||||
o_handle = mono_gchandle_new (o, TRUE);
|
||||
/* use o or mono_gchandle_get_target (o_handle) */
|
||||
...
|
||||
/* when done to allow the GC to collect o */
|
||||
mono_gchandle_free (o_handle);
|
||||
</div>
|
||||
|
||||
<h4><a name="api:mono_gchandle_new">mono_gchandle_new</a></h4>
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
<h3>Synopsis</h3>
|
||||
|
||||
<div class="mapi-header">
|
||||
<div class="header">
|
||||
#include <metadata/image.h>
|
||||
|
||||
typedef struct _MonoImage MonoImage;
|
||||
@@ -25,9 +25,9 @@ typedef enum {
|
||||
<p>Images are the actual elements in the runtime that contain
|
||||
the actual code being executed.
|
||||
|
||||
<a name="cil_image_open"/>
|
||||
<h3>Opening and closing MonoImages</h3>
|
||||
|
||||
<h4><a name="api:mono_load_image">mono_load_image</a></h4>
|
||||
<h4><a name="api:mono_image_open">mono_image_open</a></h4>
|
||||
<h4><a name="api:mono_image_open_full">mono_image_open_full</a></h4>
|
||||
<h4><a name="api:mono_image_open_from_data">mono_image_open_from_data</a></h4>
|
||||
@@ -35,8 +35,6 @@ typedef enum {
|
||||
<h4><a name="api:mono_image_close">mono_image_close</a></h4>
|
||||
<h4><a name="api:mono_image_addref">mono_image_addref</a></h4>
|
||||
<h4><a name="api:mono_image_load_file_for_image">mono_image_load_file_for_image</a></h4>
|
||||
<h4><a name="api:mono_image_open_from_data_with_name">mono_image_open_from_data_with_name</a></h4>
|
||||
<h4><a name="api:mono_image_load_module">mono_image_load_module</a></h4>
|
||||
|
||||
<h3>Image Information</h3>
|
||||
|
||||
@@ -53,7 +51,6 @@ typedef enum {
|
||||
<h4><a name="api:mono_image_loaded">mono_image_loaded</a></h4>
|
||||
<h4><a name="api:mono_image_lookup_resource">mono_image_lookup_resource</a></h4>
|
||||
<h4><a name="api:mono_image_strerror">mono_image_strerror</a></h4>
|
||||
<h4><a name="api:mono_get_method_constrained">mono_get_method_constrained</a></h4>
|
||||
|
||||
<h3>Public Keys, Strong Names and Certificates</h3>
|
||||
|
||||
@@ -67,11 +64,3 @@ typedef enum {
|
||||
<h4><a name="api:mono_image_rva_map">mono_image_rva_map</a></h4>
|
||||
<h4><a name="api:mono_image_ensure_section_idx">mono_image_ensure_section_idx</a></h4>
|
||||
<h4><a name="api:mono_image_ensure_section">mono_image_ensure_section</a></h4>
|
||||
<h4><a name="api:mono_image_init">mono_image_init</a></h4>
|
||||
<h4><a name="api:mono_images_init">mono_images_init</a></h4>
|
||||
<h4><a name="api:mono_images_cleanup">mono_images_cleanup</a></h4>
|
||||
<h4><a name="api:mono_image_add_to_name_cache">mono_image_add_to_name_cache</a></h4>
|
||||
<h4><a name="api:mono_image_fixup_vtable">mono_image_fixup_vtable</a></h4>
|
||||
<h4><a name="api:mono_image_loaded_by_guid_full">mono_image_loaded_by_guid_full</a></h4>
|
||||
<h4><a name="api:mono_image_loaded_full">mono_image_loaded_full</a></h4>
|
||||
<h4><a name="api:mono_lookup_icall_symbol">mono_lookup_icall_symbol</a></h4>
|
||||
@@ -4,29 +4,6 @@
|
||||
inside Mono that developers extending or altering Mono might
|
||||
want to use.
|
||||
|
||||
<h2>Strings</h2>
|
||||
|
||||
<h3>Other Encodings</h3>
|
||||
|
||||
<p>These routines are used when coping with strings that come
|
||||
from Mono's environment, and might be encoded in one or more
|
||||
of the external encodings.
|
||||
|
||||
<p>For example, some file systems might historically contain a
|
||||
mix of file names with both old and new encodings, typically
|
||||
UTF8 for new files, and the old files would be encoded in an 8
|
||||
bit character set (ISO-8859-1 for example).
|
||||
|
||||
<p>These routines try a number of encodings, those specified
|
||||
in the <tt>MONO_ENCODINGS</tt> environment variable and return
|
||||
unicode strings that can be used internally.
|
||||
|
||||
<p>See the mono(1) man page for more details.
|
||||
|
||||
<h4><a name="api:mono_unicode_from_external">mono_unicode_from_external</a></h4>
|
||||
<h4><a name="api:mono_unicode_to_external">mono_unicode_to_external</a></h4>
|
||||
<h4><a name="api:mono_utf8_from_external">mono_utf8_from_external</a></h4>
|
||||
|
||||
<h2>Marshalling functions</h2>
|
||||
|
||||
<h4><a name="api:mono_marshal_alloc">mono_marshal_alloc</a></h4>
|
||||
@@ -116,9 +93,12 @@
|
||||
|
||||
<h4><a name="api:mono_gc_disable">mono_gc_disable</a></h4>
|
||||
<h4><a name="api:mono_gc_enable">mono_gc_enable</a></h4>
|
||||
<h4><a name="api:mono_gc_is_finalizer_thread">mono_gc_is_finalizer_thread</a></h4>
|
||||
<h4><a name="api:mono_gc_out_of_memory">mono_gc_out_of_memory</a></h4>
|
||||
<h4><a name="api:mono_gc_start_world">mono_gc_start_world</a></h4>
|
||||
<h4><a name="api:mono_gc_stop_world">mono_gc_stop_world</a></h4>
|
||||
<h4><a name="api:mono_gc_alloc_fixed">mono_gc_alloc_fixed</a></h4>
|
||||
<h4><a name="api:mono_gc_enable_events">mono_gc_enable_events</a></h4>
|
||||
<h4><a name="api:mono_gc_free_fixed">mono_gc_free_fixed</a></h4>
|
||||
<h4><a name="api:mono_gc_make_descr_from_bitmap">mono_gc_make_descr_from_bitmap</a></h4>
|
||||
|
||||
|
||||
@@ -1,26 +1,9 @@
|
||||
<h2>Synopsis</h2>
|
||||
|
||||
<p>These functions are used to get some runtime information
|
||||
from the Just in Time compiler and also to control some
|
||||
aspects of the initialization and shutdown of the runtime.
|
||||
|
||||
<div class="mapi-header">
|
||||
typedef struct _MonoJitInfo MonoJitInfo;
|
||||
|
||||
<div class="header">
|
||||
@API_IDX@
|
||||
</div>
|
||||
|
||||
<h3>Just-in-Time Compiled Method Information</h3>
|
||||
|
||||
<p>Use the `MonoJitInfo` API to get data about a JITed
|
||||
method. These APIs are typically used by profiler modules
|
||||
added to Mono.
|
||||
|
||||
<h4><a name="api:mono_jit_info_table_find">mono_jit_info_table_find</a></h4>
|
||||
<h4><a name="api:mono_jit_info_get_code_size">mono_jit_info_get_code_size</a></h4>
|
||||
<h4><a name="api:mono_jit_info_get_code_start">mono_jit_info_get_code_start</a></h4>
|
||||
<h4><a name="api:mono_jit_info_get_method">mono_jit_info_get_method</a></h4>
|
||||
|
||||
<h3>Useful Debugging Functions</h3>
|
||||
|
||||
<p>These functions are useful when running the Mono VM inside
|
||||
@@ -31,12 +14,7 @@ typedef struct _MonoJitInfo MonoJitInfo;
|
||||
<h4><a name="api:mono_print_thread_dump">mono_print_thread_dump</a></h4>
|
||||
<h4><a name="api:mono_threads_request_thread_dump">mono_threads_request_thread_dump</a></h4>
|
||||
|
||||
<h3>Advanced</h3></h4>
|
||||
<h3>Helper Tools For Native Ports</h3>
|
||||
|
||||
<h4><a name="api:mono_inst_name">mono_inst_name</a></h4>
|
||||
|
||||
<h4><a name="api:mono_assemblies_init">mono_assemblies_init</a></h4>
|
||||
<h4><a name="api:mono_assemblies_cleanup">mono_assemblies_cleanup</a></h4>
|
||||
<h4><a name="api:mono_environment_exitcode_get">mono_environment_exitcode_get</a></h4>
|
||||
<h4><a name="api:mono_environment_exitcode_set">mono_environment_exitcode_set</a></h4>
|
||||
<h4><a name="api:mono_install_runtime_cleanup">mono_install_runtime_cleanup</a></h4>
|
||||
<h4><a name="api:mono_runtime_set_shutting_down">mono_runtime_set_shutting_down</a></h4>
|
||||
<h4><a name="api:mono_security_set_core_clr_platform_callback">mono_security_set_core_clr_platform_callback</a></h4>
|
||||
@@ -1,125 +1,4 @@
|
||||
<h2>Internal Runtime Utility Functions</h2>
|
||||
|
||||
<h3>SHA1 Signatures</h3>
|
||||
|
||||
<h4><a name="api:mono_sha1_init">mono_sha1_init</a></h4>
|
||||
<h4><a name="api:mono_sha1_update">mono_sha1_update</a></h4>
|
||||
<h4><a name="api:mono_sha1_get_digest_from_file">mono_sha1_get_digest_from_file</a></h4>
|
||||
<h4><a name="api:mono_sha1_get_digest">mono_sha1_get_digest</a></h4>
|
||||
<h4><a name="api:mono_sha1_final">mono_sha1_final</a></h4>
|
||||
|
||||
<h3>MD5 Signatures</h3>
|
||||
|
||||
<h4><a name="api:mono_md5_init">mono_md5_init</a></h4>
|
||||
<h4><a name="api:mono_md5_update">mono_md5_update</a></h4>
|
||||
<h4><a name="api:mono_md5_get_digest_from_file">mono_md5_get_digest_from_file</a></h4>
|
||||
<h4><a name="api:mono_md5_get_digest">mono_md5_get_digest</a></h4>
|
||||
<h4><a name="api:mono_md5_final">mono_md5_final</a></h4>
|
||||
|
||||
<h4><a name="api:mono_digest_get_public_token">mono_digest_get_public_token</a></h4>
|
||||
|
||||
<h3>Hashtables</h3>
|
||||
|
||||
<p><tt>GHashTable</tt> is used when you need to store object
|
||||
references into a hashtable, objects stored in a
|
||||
<tt>MonoGHashTable</tt> are properly tracked by the garbage
|
||||
collector.
|
||||
|
||||
<p>The <tt>MonoGHashTable</tt> data type has the same API as
|
||||
the GLIB.
|
||||
|
||||
<h4><a name="api:mono_g_hash_table_destroy">mono_g_hash_table_destroy</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_foreach">mono_g_hash_table_foreach</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_foreach_remove">mono_g_hash_table_foreach_remove</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_foreach_steal">mono_g_hash_table_foreach_steal</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_insert">mono_g_hash_table_insert</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_lookup">mono_g_hash_table_lookup</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_lookup_extended">mono_g_hash_table_lookup_extended</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_new">mono_g_hash_table_new</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_new_full">mono_g_hash_table_new_full</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_remap">mono_g_hash_table_remap</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_remove">mono_g_hash_table_remove</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_replace">mono_g_hash_table_replace</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_size">mono_g_hash_table_size</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_steal">mono_g_hash_table_steal</a></h4>
|
||||
|
||||
|
||||
<h3>Memory Pools</h3>
|
||||
|
||||
<p>Memory pools are a convenient way of tracking memory
|
||||
allocations that are used for one specific task, they are also
|
||||
faster than using the standard memory allocation procedures,
|
||||
as they are designed to be used only by a single thread at a
|
||||
time.
|
||||
|
||||
<p><tt>MonoMemPool</tt> objects are not thread safe, which
|
||||
means that you should not share the objects across multiple
|
||||
threads without providing proper locking around it (unlike
|
||||
<tt>malloc</tt> and <tt>free</tt> which are thread safe).
|
||||
|
||||
<p>When a <tt>MonoMemPool</tt> is released with
|
||||
<tt>mono_mempool_destroy</tt> all of the of the memory
|
||||
allocated from that memory pool with
|
||||
<tt>mono_mempool_alloc</tt> and <tt>mono_mempool_alloc0</tt>
|
||||
is released.
|
||||
|
||||
<h4><a name="api:mono_mempool_new">mono_mempool_new</a></h4>
|
||||
<h4><a name="api:mono_mempool_destroy">mono_mempool_destroy</a></h4>
|
||||
<h4><a name="api:mono_mempool_alloc">mono_mempool_alloc</a></h4>
|
||||
<h4><a name="api:mono_mempool_alloc0">mono_mempool_alloc0</a></h4>
|
||||
<h4><a name="api:mono_mempool_empty">mono_mempool_empty</a></h4>
|
||||
<h4><a name="api:mono_mempool_invalidate">mono_mempool_invalidate</a></h4>
|
||||
<h4><a name="api:mono_mempool_stats">mono_mempool_stats</a></h4>
|
||||
<h4><a name="api:mono_mempool_contains_addr">mono_mempool_contains_addr</a></h4>
|
||||
|
||||
<h3>Bitsets</h3>
|
||||
|
||||
<p>MonoBitsets are a set of routines used to manipulate sets
|
||||
of bits.
|
||||
|
||||
<h4><a name="api:mono_bitset_alloc_size">mono_bitset_alloc_size</a></h4>
|
||||
<h4><a name="api:mono_bitset_clear">mono_bitset_clear</a></h4>
|
||||
<h4><a name="api:mono_bitset_clear_all">mono_bitset_clear_all</a></h4>
|
||||
<h4><a name="api:mono_bitset_clone">mono_bitset_clone</a></h4>
|
||||
<h4><a name="api:mono_bitset_copyto">mono_bitset_copyto</a></h4>
|
||||
<h4><a name="api:mono_bitset_count">mono_bitset_count</a></h4>
|
||||
<h4><a name="api:mono_bitset_equal">mono_bitset_equal</a></h4>
|
||||
<h4><a name="api:mono_bitset_find_first">mono_bitset_find_first</a></h4>
|
||||
<h4><a name="api:mono_bitset_find_last">mono_bitset_find_last</a></h4>
|
||||
<h4><a name="api:mono_bitset_find_start">mono_bitset_find_start</a></h4>
|
||||
<h4><a name="api:mono_bitset_foreach">mono_bitset_foreach</a></h4>
|
||||
<h4><a name="api:mono_bitset_free">mono_bitset_free</a></h4>
|
||||
<h4><a name="api:mono_bitset_intersection">mono_bitset_intersection</a></h4>
|
||||
<h4><a name="api:mono_bitset_invert">mono_bitset_invert</a></h4>
|
||||
<h4><a name="api:mono_bitset_mem_new">mono_bitset_mem_new</a></h4>
|
||||
<h4><a name="api:mono_bitset_new">mono_bitset_new</a></h4>
|
||||
<h4><a name="api:mono_bitset_set">mono_bitset_set</a></h4>
|
||||
<h4><a name="api:mono_bitset_set_all">mono_bitset_set_all</a></h4>
|
||||
<h4><a name="api:mono_bitset_size">mono_bitset_size</a></h4>
|
||||
<h4><a name="api:mono_bitset_sub">mono_bitset_sub</a></h4>
|
||||
<h4><a name="api:mono_bitset_test">mono_bitset_test</a></h4>
|
||||
<h4><a name="api:mono_bitset_test_bulk">mono_bitset_test_bulk</a></h4>
|
||||
<h4><a name="api:mono_bitset_union">mono_bitset_union</a></h4>
|
||||
<h4><a name="api:mono_bitset_find_first_unset">mono_bitset_find_first_unset</a></h4>
|
||||
<h4><a name="api:mono_bitset_intersection_2">mono_bitset_intersection_2</a></h4>
|
||||
|
||||
<h3>JIT utilities</h3>
|
||||
|
||||
<h4><a name="api:mono_signbit_double">mono_signbit_double</a></h4>
|
||||
<h4><a name="api:mono_signbit_float">mono_signbit_float</a></h4>
|
||||
|
||||
<h3>Function Pointers</h3>
|
||||
|
||||
<p>To wrap a function pointer into something that the Mono
|
||||
runtime can consume, you should use the mono_create_ftnptr.
|
||||
This is only important if you plan on running on the IA64
|
||||
architecture. Otherwise you can just use the function
|
||||
pointer address.
|
||||
|
||||
<h4><a name="api:mono_create_ftnptr">mono_create_ftnptr</a></h4>
|
||||
|
||||
|
||||
<h2>Notification Interface</h2>
|
||||
<h1>Notification Interface</h1>
|
||||
|
||||
<p>This is an internal profiler interface. In general, users
|
||||
would not be using this interface, but would be using the
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
|
||||
|
||||
<h4><a name="api:mono_delegate_free_ftnptr">mono_delegate_free_ftnptr</a></h4>
|
||||
<h4><a name="api:mono_delegate_to_ftnptr">mono_delegate_to_ftnptr</a></h4>
|
||||
<h4><a name="api:mono_ftnptr_to_delegate">mono_ftnptr_to_delegate</a></h4>
|
||||
<h4><a name="api:mono_marshal_string_to_utf16">mono_marshal_string_to_utf16</a></h4>
|
||||
@@ -617,6 +617,7 @@ MONO_TYPESPEC_SIZE
|
||||
|
||||
<h4><a name="api:mono_image_get_table_info">mono_image_get_table_info</a></h4>
|
||||
<h4><a name="api:mono_image_get_table_rows">mono_image_get_table_rows</a></h4>
|
||||
<h4><a name="api:mono_metadata_get_table">mono_metadata_get_table</a></h4>
|
||||
<h4><a name="api:mono_metadata_decode_row_col">mono_metadata_decode_row_col</a></h4>
|
||||
<h4><a name="api:mono_metadata_decode_row">mono_metadata_decode_row</a></h4>
|
||||
<h4><a name="api:mono_metadata_compute_size">mono_metadata_compute_size</a></h4>
|
||||
@@ -630,10 +631,9 @@ MONO_TYPESPEC_SIZE
|
||||
<p>This is the low-level API for accessing the metadata
|
||||
images.
|
||||
|
||||
<h4><a name="api:mono_cli_rva_image_map">mono_cli_rva_image_map</a></h4>
|
||||
<h4><a name="api:mono_pe_file_open">mono_pe_file_open</a></h4>
|
||||
<h4><a name="api:mono_metadata_events_from_typedef">mono_metadata_events_from_typedef</a></h4>
|
||||
<h4><a name="api:mono_metadata_decode_table_row">mono_metadata_decode_table_row</a></h4>
|
||||
<h4><a name="api:mono_metadata_decode_table_row_col">mono_metadata_decode_table_row_col</a></h4>
|
||||
<h4><a name="api:mono_metadata_field_info">mono_metadata_field_info</a></h4>
|
||||
<h4><a name="api:mono_metadata_free_array">mono_metadata_free_array</a></h4>
|
||||
<h4><a name="api:mono_metadata_free_marshal_spec">mono_metadata_free_marshal_spec</a></h4>
|
||||
@@ -652,7 +652,6 @@ MONO_TYPESPEC_SIZE
|
||||
<h4><a name="api:mono_metadata_packing_from_typedef">mono_metadata_packing_from_typedef</a></h4>
|
||||
<h4><a name="api:mono_metadata_properties_from_typedef">mono_metadata_properties_from_typedef</a></h4>
|
||||
<h4><a name="api:mono_metadata_token_from_dor">mono_metadata_token_from_dor</a></h4>
|
||||
<h4><a name="api:mono_metadata_translate_token_index">mono_metadata_translate_token_index</a></h4>
|
||||
<h4><a name="api:mono_metadata_typedef_from_field">mono_metadata_typedef_from_field</a></h4>
|
||||
<h4><a name="api:mono_metadata_typedef_from_method">mono_metadata_typedef_from_method</a></h4>
|
||||
<h4><a name="api:mono_metadata_type_equal">mono_metadata_type_equal</a></h4>
|
||||
@@ -662,23 +661,24 @@ MONO_TYPESPEC_SIZE
|
||||
|
||||
<h3>Retrieving Objects from Tokens</h3>
|
||||
|
||||
<h4><a name="api:mono_metadata_parse_array">mono_metadata_parse_array</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_custom_mod">mono_metadata_parse_custom_mod</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_field_type">mono_metadata_parse_field_type</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_marshal_spec">mono_metadata_parse_marshal_spec</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_method_signature_full">mono_metadata_parse_method_signature_full</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_method_signature">mono_metadata_parse_method_signature</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_mh_full">mono_metadata_parse_mh_full</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_mh">mono_metadata_parse_mh</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_param">mono_metadata_parse_param</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_ret_type">mono_metadata_parse_ret_type</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_signature">mono_metadata_parse_signature</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_typedef_or_ref">mono_metadata_parse_typedef_or_ref</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_type_full">mono_metadata_parse_type_full</a></h4>
|
||||
<h4><a name="api:mono_metadata_parse_type">mono_metadata_parse_type</a></h4>
|
||||
|
||||
<h2>Generics Support</h2>
|
||||
|
||||
<h4><a name="api:mono_metadata_generic_class_equal">mono_metadata_generic_class_equal</a></h4>
|
||||
<h4><a name="api:mono_metadata_generic_class_hash">mono_metadata_generic_class_hash</a></h4>
|
||||
<h4><a name="api:mono_metadata_generic_class_is_valuetype">mono_metadata_generic_class_is_valuetype</a></h4>
|
||||
<h4><a name="api:mono_metadata_inflate_generic_inst">mono_metadata_inflate_generic_inst</a></h4>
|
||||
<h4><a name="api:mono_metadata_load_generic_params">mono_metadata_load_generic_params</a></h4>
|
||||
|
||||
<h2>Tokens</h2>
|
||||
|
||||
|
||||
@@ -1,159 +1,5 @@
|
||||
<h2>Methods</h2>
|
||||
<h3>Methods</h3>
|
||||
|
||||
<p>Methods are represented by the <code>MonoMethod*</code>
|
||||
instances. Various APIs surface these instances, but usually
|
||||
you will use the <a href="#method-desc">method description</a>
|
||||
API to get a handle to a Mono Method. You can <a href="method-invoking">invoke</a> those methods from C,
|
||||
or you can probe <a href="method-working">probe various properties</a> of a method, and in particular
|
||||
its <a href="method-signature">method signature</a> or get
|
||||
some <a href="method-header">low-level information</a> about them.
|
||||
|
||||
<p>The following code snippet from the Mono runtime shows you
|
||||
how to create a managed <code>System.Version</code> instance
|
||||
with four integers by looking up the constructor in the
|
||||
managed implementation of System.Version, creating an instance
|
||||
of the object, and then invoking the constructor on it.
|
||||
|
||||
<div class="mapi-header">
|
||||
MonoObject*
|
||||
create_version (MonoDomain *domain, guint32 major, guint32 minor, guint32 build, guint32 revision)
|
||||
{
|
||||
MonoClass *System_Version;
|
||||
MonoMethod *create_version;
|
||||
MonoError error;
|
||||
MonoObject *result;
|
||||
gpointer args [4];
|
||||
|
||||
System_Version = mono_class_from_name (mono_defaults.corlib, "System", "Version");
|
||||
|
||||
// Create a method description that we use to search for the
|
||||
// constructor method
|
||||
MonoMethodDesc *desc = mono_method_desc_new (":.ctor(int,int,int,int)", FALSE);
|
||||
create_version = mono_method_desc_search_in_class (desc, System_Version);
|
||||
mono_method_desc_free (desc);
|
||||
|
||||
// Setup the parameters to pass.
|
||||
args [0] = &major;
|
||||
args [1] = &minor;
|
||||
args [2] = &build;
|
||||
args [3] = &revision;
|
||||
|
||||
// Create the object instance
|
||||
result = mono_object_new_checked (domain, System_Version, &error);
|
||||
|
||||
// Raise an exception in case of an error
|
||||
mono_error_raise_exception (&error);
|
||||
|
||||
// Otherwise, invoke the constructor
|
||||
mono_runtime_invoke (create_version, result, args, NULL);
|
||||
|
||||
// Return ther esult
|
||||
return result;
|
||||
}
|
||||
|
||||
</div>
|
||||
|
||||
<a name="method-desc"></a>
|
||||
<h3>Method Descriptions</h3>
|
||||
|
||||
<p>Methods are represented by the <code>MonoMethod*</code>
|
||||
instances. To simplify the process of getting
|
||||
a <code>MonoMethod*</code>, you use Method Descriptors, which
|
||||
are C-strings that describe the method that you are looking
|
||||
for, and then you perform a search in either
|
||||
a <a href="mono-api-type.html">type</a>, or a
|
||||
loaded <a href="mono-api-image.html">image</a>.
|
||||
|
||||
|
||||
<p>To describe a method, you use the Method Description API.
|
||||
Method descriptions are used to locate a method in the
|
||||
executing program. They can either be fully specified, that
|
||||
is, they would include the namespace, class, method name and
|
||||
all of its arguments or they omit the namespace and arguments
|
||||
and even use wildcard matches for the class name and method names.
|
||||
|
||||
<p>You use the fully specified version to identify a
|
||||
particular method, or you can use the partial version to find
|
||||
a method or a family of methods in the code.
|
||||
|
||||
<p>Method descriptions are typically created from a C string
|
||||
representation, and take the following form:
|
||||
|
||||
<p><code>[namespace.]classname:methodname[(args...)]</code>
|
||||
|
||||
<p>Both classname and methodname can contain the '*' character
|
||||
which can be used to match anything. Arguments are separated
|
||||
by commas.
|
||||
|
||||
<p>You can use the type shortcuts to match the fully qualified
|
||||
parameter types. The supported type shortcuts are:
|
||||
<code>char</code>,
|
||||
<code>bool</code>,
|
||||
<code>byte</code>,
|
||||
<code>sbyte</code>,
|
||||
<code>uint16</code>,
|
||||
<code>int16</code>,
|
||||
<code>uint</code>,
|
||||
<code>int</code>,
|
||||
<code>ulong</code>,
|
||||
<code>long</code>,
|
||||
<code>uintptr</code>,
|
||||
<code>intptr</code>,
|
||||
<code>single</code>,
|
||||
<code>double</code>,
|
||||
<code>string</code> and
|
||||
<code>object</code>.
|
||||
|
||||
<p>The type parameters can use the "&" and "*" type modifiers.
|
||||
|
||||
<p>Examples of method descriptions:
|
||||
<ul>
|
||||
<li>"Monitor:Exit": matches classes and methods called "Monitor.Exit"
|
||||
<li>"Monitor:enter_with_atomic_var(object,bool&)":
|
||||
matches a method in the class Monitor with two
|
||||
specific type parameters.
|
||||
<li>":.ctor(int,int,int,int)": matches constructors
|
||||
that take four integers.
|
||||
<li>"System.Globalization.CultureInfo:CreateCulture(string,bool)":
|
||||
matches the CreateCultureMethod that takes a string
|
||||
and a boolean on the System.Globalization.CultureInfo class.
|
||||
</ul>
|
||||
|
||||
<p>You can
|
||||
then <a href="api:mono_method_desc_search_in_image">search for
|
||||
methods in MonoImages</a>
|
||||
or <a href="api:mono_method_desc_search_in_class">search for
|
||||
methods in classes</a>.
|
||||
|
||||
<h4><a name="api:mono_method_desc_new">mono_method_desc_new</a></h4>
|
||||
<h4><a name="api:mono_method_desc_free">mono_method_desc_free</a></h4>
|
||||
<h4><a name="api:mono_method_desc_from_method">mono_method_desc_from_method</a></h4>
|
||||
<h4><a name="api:mono_method_desc_full_match">mono_method_desc_full_match</a></h4>
|
||||
<h4><a name="api:mono_method_desc_match">mono_method_desc_match</a></h4>
|
||||
<h4><a name="api:mono_method_desc_search_in_class">mono_method_desc_search_in_class</a></h4>
|
||||
<h4><a name="api:mono_method_desc_search_in_image">mono_method_desc_search_in_image</a></h4>
|
||||
|
||||
<a name="method-working"></a>
|
||||
<h3>Working with Methods</h3>
|
||||
|
||||
<h4><a name="api:mono_method_full_name">mono_method_full_name</a></h4>
|
||||
<h4><a name="api:mono_method_get_class">mono_method_get_class</a></h4>
|
||||
<h4><a name="api:mono_method_get_flags">mono_method_get_flags</a></h4>
|
||||
<h4><a name="api:mono_method_get_last_managed">mono_method_get_last_managed</a></h4>
|
||||
<h4><a name="api:mono_method_get_marshal_info">mono_method_get_marshal_info</a></h4>
|
||||
<h4><a name="api:mono_method_get_name">mono_method_get_name</a></h4>
|
||||
<h4><a name="api:mono_method_get_object">mono_method_get_object</a></h4>
|
||||
<h4><a name="api:mono_method_get_param_names">mono_method_get_param_names</a></h4>
|
||||
<h4><a name="api:mono_method_get_param_token">mono_method_get_param_token</a></h4>
|
||||
<h4><a name="api:mono_method_get_signature">mono_method_get_signature</a></h4>
|
||||
<h4><a name="api:mono_method_get_index">mono_method_get_index</a></h4>
|
||||
<h4><a name="api:mono_method_get_signature_full">mono_method_get_signature_full</a></h4>
|
||||
<h4><a name="api:mono_method_get_token">mono_method_get_token</a></h4>
|
||||
<h4><a name="api:mono_method_get_unmanaged_thunk">mono_method_get_unmanaged_thunk</a></h4>
|
||||
<h4><a name="api:mono_method_has_marshal_info">mono_method_has_marshal_info</a></h4>
|
||||
<h4><a name="api:mono_method_verify">mono_method_verify</a></h4>
|
||||
|
||||
<a name="method-invoking"></a>
|
||||
<h3>Invoking Methods</h3>
|
||||
|
||||
<h4><a name="api:mono_runtime_invoke">mono_runtime_invoke</a></h4>
|
||||
@@ -162,7 +8,7 @@ If you want to invoke generic methods, you must call the method on the
|
||||
"inflated" class, which you can obtain from the
|
||||
<tt>mono_object_get_class()</tt>
|
||||
|
||||
<div class="mapi-code">
|
||||
<div class="code">
|
||||
MonoClass *clazz;
|
||||
MonoMethod *method;
|
||||
|
||||
@@ -183,8 +29,29 @@ mono_runtime_invoke (method, obj, args, &exception);
|
||||
<h4><a name="api:mono_runtime_delegate_invoke">mono_runtime_delegate_invoke</a></h4>
|
||||
|
||||
<h4><a name="api:mono_method_body_get_object">mono_method_body_get_object</a></h4>
|
||||
<h4><a name="api:mono_method_desc_free">mono_method_desc_free</a></h4>
|
||||
<h4><a name="api:mono_method_desc_from_method">mono_method_desc_from_method</a></h4>
|
||||
<h4><a name="api:mono_method_desc_full_match">mono_method_desc_full_match</a></h4>
|
||||
<h4><a name="api:mono_method_desc_match">mono_method_desc_match</a></h4>
|
||||
<h4><a name="api:mono_method_desc_new">mono_method_desc_new</a></h4>
|
||||
<h4><a name="api:mono_method_desc_search_in_class">mono_method_desc_search_in_class</a></h4>
|
||||
<h4><a name="api:mono_method_desc_search_in_image">mono_method_desc_search_in_image</a></h4>
|
||||
<h4><a name="api:mono_method_full_name">mono_method_full_name</a></h4>
|
||||
<h4><a name="api:mono_method_get_class">mono_method_get_class</a></h4>
|
||||
<h4><a name="api:mono_method_get_flags">mono_method_get_flags</a></h4>
|
||||
<h4><a name="api:mono_method_get_last_managed">mono_method_get_last_managed</a></h4>
|
||||
<h4><a name="api:mono_method_get_marshal_info">mono_method_get_marshal_info</a></h4>
|
||||
<h4><a name="api:mono_method_get_name">mono_method_get_name</a></h4>
|
||||
<h4><a name="api:mono_method_get_object">mono_method_get_object</a></h4>
|
||||
<h4><a name="api:mono_method_get_param_names">mono_method_get_param_names</a></h4>
|
||||
<h4><a name="api:mono_method_get_param_token">mono_method_get_param_token</a></h4>
|
||||
<h4><a name="api:mono_method_get_signature">mono_method_get_signature</a></h4>
|
||||
<h4><a name="api:mono_method_get_index">mono_method_get_index</a></h4>
|
||||
<h4><a name="api:mono_method_get_signature_full">mono_method_get_signature_full</a></h4>
|
||||
<h4><a name="api:mono_method_get_token">mono_method_get_token</a></h4>
|
||||
<h4><a name="api:mono_method_has_marshal_info">mono_method_has_marshal_info</a></h4>
|
||||
<h4><a name="api:mono_method_verify">mono_method_verify</a></h4>
|
||||
|
||||
<a name="method-signature"></a>
|
||||
<h3>Method Signatures</h3>
|
||||
|
||||
<h4><a name="api:mono_method_signature">mono_method_signature</a></h4>
|
||||
@@ -196,13 +63,11 @@ mono_runtime_invoke (method, obj, args, &exception);
|
||||
<h4><a name="api:mono_signature_get_return_type">mono_signature_get_return_type</a></h4>
|
||||
<h4><a name="api:mono_signature_hash">mono_signature_hash</a></h4>
|
||||
<h4><a name="api:mono_signature_is_instance">mono_signature_is_instance</a></h4>
|
||||
<h4><a name="api:mono_signature_param_is_out">mono_signature_param_is_out</a></h4>
|
||||
<h4><a name="api:mono_signature_vararg_start">mono_signature_vararg_start</a></h4>
|
||||
<h4><a name="api:mono_param_get_objects">mono_param_get_objects</a></h4>
|
||||
<h4><a name="api:mono_get_method_full">mono_get_method_full</a></h4>
|
||||
<h4><a name="api:mono_get_method">mono_get_method</a></h4>
|
||||
|
||||
<a name="method-header"></a>
|
||||
<h3>Methods Header Operations</h3>
|
||||
|
||||
<h4><a name="api:mono_method_get_header">mono_method_get_header</a></h4>
|
||||
|
||||
@@ -6,17 +6,15 @@
|
||||
|
||||
<p>The object API has methods for accessing <a
|
||||
href="#fields">fields</a>, <a
|
||||
href="#properties">properties</a>, <a href="mono-api-methods.html">methods</a>, <a
|
||||
href="#properties">properties</a>, <a
|
||||
href="#events">events</a>, <a href="#delegates">delegates</a>.
|
||||
|
||||
|
||||
|
||||
<p>There are some advanced uses that are useful to document
|
||||
here dealing with <a href="#remote">remote fields</a>.
|
||||
|
||||
<h2>Synopsis</h2>
|
||||
|
||||
<div class="mapi-header">
|
||||
<div class="header">
|
||||
#include <metadata/object.h>
|
||||
|
||||
typedef struct MonoVTable MonoVTable;
|
||||
@@ -45,7 +43,7 @@ typedef struct {
|
||||
@API_IDX@
|
||||
</div>
|
||||
|
||||
<p>`MonoObject` is the base definition for all managed objects
|
||||
<p>MonoObject is the base definition for all managed objects
|
||||
in the Mono runtime, it represents the <a
|
||||
href="http://www.mono-project.com/monodoc/T:System.Object">System.Object</a>
|
||||
managed type.
|
||||
@@ -56,11 +54,12 @@ typedef struct {
|
||||
following the pattern where the parent class is the first
|
||||
field of a structure definition, for example:
|
||||
|
||||
<div class="mapi-code">
|
||||
typedef struct {
|
||||
MonoObject parent;
|
||||
int my_new_field;
|
||||
} MyNewObject</div>
|
||||
<div class="code">
|
||||
typedef struct {
|
||||
MonoObject parent;
|
||||
int my_new_field;
|
||||
} MyNewObject
|
||||
</div>
|
||||
|
||||
<a name="objects"></a>
|
||||
<h2>Core Object Methods</h2>
|
||||
@@ -70,7 +69,7 @@ typedef struct {
|
||||
<p>For example, if you wanted to create an object of type
|
||||
System.Version, you would use a piece of code like this:
|
||||
|
||||
<div class="mapi-code">
|
||||
<div class="code">
|
||||
MonoClass *version_class;
|
||||
MonoObject *result;
|
||||
|
||||
@@ -80,7 +79,7 @@ version_class = mono_class_from_name (mono_get_corlib (),
|
||||
|
||||
/* Create an object of that class */
|
||||
result = mono_object_new (mono_domain_get (), version_class);
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h4><a name="api:mono_object_new_alloc_specific">mono_object_new_alloc_specific</a></h4>
|
||||
<h4><a name="api:mono_object_new_fast">mono_object_new_fast</a></h4>
|
||||
@@ -94,9 +93,8 @@ result = mono_object_new (mono_domain_get (), version_class);
|
||||
<h4><a name="api:mono_object_isinst">mono_object_isinst</a></h4>
|
||||
<h4><a name="api:mono_object_unbox">mono_object_unbox</a></h4>
|
||||
<h4><a name="api:mono_object_castclass_mbyref">mono_object_castclass_mbyref</a></h4>
|
||||
<h4><a name="api:mono_object_is_alive">mono_object_is_alive</a></h4>
|
||||
<h4><a name="api:mono_object_get_size">mono_object_get_size</a></h4>
|
||||
<h4><a name="api:mono_object_hash">mono_object_hash</a></h4>
|
||||
<h4><a name="api:mono_object_to_string">mono_object_to_string</a></h4>
|
||||
|
||||
<a name="valuetypes"></a>
|
||||
<h2>Value Types</h2>
|
||||
@@ -115,17 +113,19 @@ result = mono_object_new (mono_domain_get (), version_class);
|
||||
elements of type <tt>System.Byte</tt>, and sets the values
|
||||
0xca and 0xfe on it:
|
||||
|
||||
<pre class="mapi-code">
|
||||
MonoArray *CreateByteArray (MonoDomain *domain)
|
||||
{
|
||||
MonoArray *data;
|
||||
<pre class="code">
|
||||
|
||||
data = mono_array_new (domain, mono_get_byte_class (), 2);
|
||||
mono_array_set (data, guint8, 0, 0xca);
|
||||
mono_array_set (data, guint8, 0, 0xfe);
|
||||
MonoArray *CreateByteArray (MonoDomain *domain)
|
||||
{
|
||||
MonoArray *data;
|
||||
|
||||
data = mono_array_new (domain, mono_get_byte_class (), 2);
|
||||
mono_array_set (data, guint8, 0, 0xca);
|
||||
mono_array_set (data, guint8, 0, 0xfe);
|
||||
|
||||
return data;
|
||||
}
|
||||
|
||||
return data;
|
||||
}
|
||||
</pre>
|
||||
|
||||
<h3>Creating Arrays</h3>
|
||||
@@ -138,31 +138,12 @@ MonoArray *CreateByteArray (MonoDomain *domain)
|
||||
|
||||
<h3>Using Arrays</h3>
|
||||
|
||||
<p>Arrays are represented by the `MonoArray` data type and are
|
||||
instances of `MonoObject`. While you can use the `bounds`
|
||||
and `max_length` fields of the type, the actual storage
|
||||
(represented by `vector`) is not very useful. Instead you
|
||||
should use one of the accesor methods described below to
|
||||
fetch or set the values in the array.
|
||||
|
||||
<p>When setting values in an array, you should
|
||||
use <a href="api:mono_array_set">mono_array_set</a> for
|
||||
setting elements in an array that contains value types, and
|
||||
<a
|
||||
href="api:mono_array_setref">mono_array_setref</a> for arrays
|
||||
that contain reference types.
|
||||
|
||||
<p>The <a href="api:mono_array_get">mono_array_get</a>,
|
||||
<a href="api:mono_array_set">mono_array_set</a> and <a
|
||||
href="api:mono_array_setref">mono_array_setref</a> are C
|
||||
macros that wrap the underlying array access.
|
||||
|
||||
<h4><a name="api:mono_array_get">mono_array_get</a></h4>
|
||||
<h4><a name="api:mono_array_length">mono_array_length</a></h4>
|
||||
<h4><a name="api:mono_array_set">mono_array_set</a></h4>
|
||||
<h4><a name="api:mono_array_setref">mono_array_setref</a></h4>
|
||||
<h4><a name="api:mono_array_length">mono_array_length</a></h4>
|
||||
<h4><a name="api:mono_array_addr">mono_array_addr</a></h4>
|
||||
<h4><a name="api:mono_array_addr_with_size">mono_array_addr_with_size</a></h4>
|
||||
<h4><a name="api:mono_array_get">mono_array_get</a></h4>
|
||||
<h4><a name="api:mono_array_element_size">mono_array_element_size</a></h4>
|
||||
|
||||
<a name="fields"></a>
|
||||
@@ -210,7 +191,3 @@ MonoArray *CreateByteArray (MonoDomain *domain)
|
||||
<h4><a name="api:mono_store_remote_field">mono_store_remote_field</a></h4>
|
||||
<h4><a name="api:mono_store_remote_field_new">mono_store_remote_field_new</a></h4>
|
||||
|
||||
<a name="delegates"></a>
|
||||
<h2>Delegates</h2>
|
||||
<h4><a name="api:mono_get_delegate_begin_invoke">mono_get_delegate_begin_invoke</a></h4>
|
||||
<h4><a name="api:mono_get_delegate_end_invoke">mono_get_delegate_end_invoke</a></h4>
|
||||
@@ -1,16 +1,11 @@
|
||||
<h2>Fetching Types, and Basic Reflection</h2>
|
||||
|
||||
<h4><a name="api:mono_custom_attrs_get_attr">mono_custom_attrs_get_attr</a></h4>
|
||||
<h4><a name="api:mono_reflection_assembly_get_assembly">mono_reflection_assembly_get_assembly</a></h4>
|
||||
<h4><a name="api:mono_reflection_free_type_info">mono_reflection_free_type_info</a></h4>
|
||||
<h4><a name="api:mono_reflection_get_custom_attrs_blob">mono_reflection_get_custom_attrs_blob</a></h4>
|
||||
<h4><a name="api:mono_reflection_get_custom_attrs_by_type">mono_reflection_get_custom_attrs_by_type</a></h4>
|
||||
<h4><a name="api:mono_reflection_get_custom_attrs_data">mono_reflection_get_custom_attrs_data</a></h4>
|
||||
<h4><a name="api:mono_reflection_get_custom_attrs">mono_reflection_get_custom_attrs</a></h4>
|
||||
<h4><a name="api:mono_custom_attrs_get_attr">mono_custom_attrs_get_attr</a></h4>
|
||||
<h4><a name="api:mono_reflection_get_token">mono_reflection_get_token</a></h4>
|
||||
<h4><a name="api:mono_reflection_get_type">mono_reflection_get_type</a></h4>
|
||||
<h4><a name="api:mono_reflection_parse_type">mono_reflection_parse_type</a></h4>
|
||||
<h4><a name="api:mono_reflection_type_get_type">mono_reflection_type_get_type</a></h4>
|
||||
<h4><a name="api:mono_reflection_type_from_name">mono_reflection_type_from_name</a></h4>
|
||||
<h4><a name="api:mono_reflection_get_custom_attrs_info">mono_reflection_get_custom_attrs_info</a></h4>
|
||||
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
<h3>Security Manager</h3>
|
||||
|
||||
<h4><a name="api:mono_get_context_capture_method">mono_get_context_capture_method</a></h4>
|
||||
|
||||
<h3>Declarative Security</h3>
|
||||
|
||||
<h4><a name="api:mono_declsec_flags_from_assembly">mono_declsec_flags_from_assembly</a></h4>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
<h3>Synopsis</h3>
|
||||
|
||||
<div class="mapi-header">
|
||||
<div class="header">
|
||||
#include <metadata/object.h>
|
||||
|
||||
typedef struct {
|
||||
@@ -17,10 +17,10 @@ typedef struct {
|
||||
</div>
|
||||
|
||||
<p>All of the operations on strings are done on pointers to
|
||||
`MonoString` objects, like this:
|
||||
MonoString objects, like this:
|
||||
|
||||
<div class="mapi-code">
|
||||
MonoString *hello = mono_string_new (mono_domain_get (), "hello, world");
|
||||
<div class="code">
|
||||
MonoString *hello = mono_string_new (mono_domain_get (), "hello, world");
|
||||
</div>
|
||||
|
||||
<p>Strings are bound to a particular application domain, which
|
||||
@@ -37,16 +37,12 @@ MonoString *hello = mono_string_new (mono_domain_get (), "hello, world");
|
||||
<h4><a name="api:mono_string_new_len">mono_string_new_len</a></h4>
|
||||
<h4><a name="api:mono_string_new_size">mono_string_new_size</a></h4>
|
||||
<h4><a name="api:mono_string_new_utf16">mono_string_new_utf16</a></h4>
|
||||
<h4><a name="api:mono_string_new_utf32">mono_string_new_utf32</a></h4>
|
||||
<h4><a name="api:mono_string_from_utf16">mono_string_from_utf16</a></h4>
|
||||
<h4><a name="api:mono_string_from_utf32">mono_string_from_utf32</a></h4>
|
||||
|
||||
<h3>Conversions</h3>
|
||||
|
||||
<h4><a name="api:mono_string_to_utf16">mono_string_to_utf16</a></h4>
|
||||
<h4><a name="api:mono_string_to_utf8">mono_string_to_utf8</a></h4>
|
||||
<h4><a name="api:mono_string_to_utf8_checked">mono_string_to_utf8_checked</a></h4>
|
||||
<h4><a name="api:mono_string_to_utf32">mono_string_to_utf32</a></h4>
|
||||
|
||||
<h3>Methods</h3>
|
||||
|
||||
@@ -59,3 +55,23 @@ MonoString *hello = mono_string_new (mono_domain_get (), "hello, world");
|
||||
<h4><a name="api:mono_string_length">mono_string_length</a></h4>
|
||||
|
||||
|
||||
<h3>Other Encodings</h3>
|
||||
|
||||
<p>These routines are used when coping with strings that come
|
||||
from Mono's environment, and might be encoded in one or more
|
||||
of the external encodings.
|
||||
|
||||
<p>For example, some file systems might historically contain a
|
||||
mix of file names with both old and new encodings, typically
|
||||
UTF8 for new files, and the old files would be encoded in an 8
|
||||
bit character set (ISO-8859-1 for example).
|
||||
|
||||
<p>These routines try a number of encodings, those specified
|
||||
in the <tt>MONO_ENCODINGS</tt> environment variable and return
|
||||
unicode strings that can be used internally.
|
||||
|
||||
<p>See the mono(1) man page for more details.
|
||||
|
||||
<h4><a name="api:mono_unicode_from_external">mono_unicode_from_external</a></h4>
|
||||
<h4><a name="api:mono_unicode_to_external">mono_unicode_to_external</a></h4>
|
||||
<h4><a name="api:mono_utf8_from_external">mono_utf8_from_external</a></h4>
|
||||
@@ -6,28 +6,19 @@
|
||||
<h4><a name="api:mono_thread_current">mono_thread_current</a></h4>
|
||||
<h4><a name="api:mono_thread_detach">mono_thread_detach</a></h4>
|
||||
<h4><a name="api:mono_thread_exit">mono_thread_exit</a></h4>
|
||||
<h4><a name="api:mono_thread_get_managed_id">mono_thread_get_managed_id</a></h4>
|
||||
<h4><a name="api:mono_thread_get_name_utf8">mono_thread_get_name_utf8</a></h4>
|
||||
<h4><a name="api:mono_thread_is_foreign">mono_thread_is_foreign</a></h4>
|
||||
<h4><a name="api:mono_thread_manage">mono_thread_manage</a></h4>
|
||||
<h4><a name="api:mono_thread_new_init">mono_thread_new_init</a></h4>
|
||||
<h4><a name="api:mono_threads_get_default_stacksize">mono_threads_get_default_stacksize</a></h4>
|
||||
<h4><a name="api:mono_threads_install_cleanup">mono_threads_install_cleanup</a></h4>
|
||||
<h4><a name="api:mono_threads_set_default_stacksize">mono_threads_set_default_stacksize</a></h4>
|
||||
<h4><a name="api:mono_thread_set_manage_callback">mono_thread_set_manage_callback</a></h4>
|
||||
<h4><a name="api:mono_thread_stop">mono_thread_stop</a></h4>
|
||||
|
||||
<h4><a name="api:mono_thread_get_main">mono_thread_get_main</a></h4>
|
||||
<h4><a name="api:mono_thread_set_main">mono_thread_set_main</a></h4>
|
||||
<h4><a name="api:mono_pthread_key_for_tls">mono_pthread_key_for_tls</a></h4>
|
||||
|
||||
<h3>Monitors</h3>
|
||||
|
||||
<h4><a name="api:mono_monitor_enter">mono_monitor_enter</a></h4>
|
||||
<h4><a name="api:mono_monitor_enter_v4">mono_monitor_enter_v4</a></h4>
|
||||
<h4><a name="api:mono_monitor_exit">mono_monitor_exit</a></h4>
|
||||
<h4><a name="api:mono_monitor_try_enter">mono_monitor_try_enter</a></h4>
|
||||
|
||||
<h3>Initialization and Shutdown</h3>
|
||||
|
||||
<h4><a name="api:mono_thread_cleanup">mono_thread_cleanup</a></h4>
|
||||
<h4><a name="api:mono_thread_detach_if_exiting">mono_thread_detach_if_exiting</a></h4>
|
||||
<h4><a name="api:mono_thread_init">mono_thread_init</a></h4>
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<h3>Synopsis</h3>
|
||||
|
||||
<div class="mapi-header">
|
||||
<div class="header">
|
||||
#include <metadata/metadata.h>
|
||||
#include <metadata/class.h>
|
||||
|
||||
@@ -19,17 +19,13 @@ typedef struct _MonoType MonoType;
|
||||
<h4><a name="api:mono_type_full_name">mono_type_full_name</a></h4>
|
||||
<h4><a name="api:mono_type_get_array_type">mono_type_get_array_type</a></h4>
|
||||
<h4><a name="api:mono_type_get_class">mono_type_get_class</a></h4>
|
||||
<h4><a name="api:mono_type_get_desc">mono_type_get_desc</a></h4>
|
||||
<h4><a name="api:mono_type_get_modifiers">mono_type_get_modifiers</a></h4>
|
||||
<h4><a name="api:mono_type_get_name">mono_type_get_name</a></h4>
|
||||
<h4><a name="api:mono_type_get_ptr_type">mono_type_get_ptr_type</a></h4>
|
||||
<h4><a name="api:mono_type_get_signature">mono_type_get_signature</a></h4>
|
||||
<h4><a name="api:mono_type_get_type">mono_type_get_type</a></h4>
|
||||
<h4><a name="api:mono_type_get_underlying_type">mono_type_get_underlying_type</a></h4>
|
||||
<h4><a name="api:mono_type_is_byref">mono_type_is_byref</a></h4>
|
||||
<h4><a name="api:mono_type_is_pointer">mono_type_is_pointer</a></h4>
|
||||
<h4><a name="api:mono_type_is_reference">mono_type_is_reference</a></h4>
|
||||
<h4><a name="api:mono_type_is_struct">mono_type_is_struct</a></h4>
|
||||
<h4><a name="api:mono_type_is_void">mono_type_is_void</a></h4>
|
||||
<h4><a name="api:mono_type_size">mono_type_size</a></h4>
|
||||
<h4><a name="api:mono_type_stack_size">mono_type_stack_size</a></h4>
|
||||
<h4><a name="api:mono_type_to_unmanaged">mono_type_to_unmanaged</a></h4>
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
<h4><a name="api:mono_compile_method">mono_compile_method</a></h4>
|
||||
<h4><a name="api:mono_config_for_assembly">mono_config_for_assembly</a></h4>
|
||||
<h4><a name="api:mono_dllmap_insert">mono_dllmap_insert</a></h4>
|
||||
<h4><a name="api:mono_environment_exitcode_get">mono_environment_exitcode_get</a></h4>
|
||||
<h4><a name="api:mono_environment_exitcode_set">mono_environment_exitcode_set</a></h4>
|
||||
<h4><a name="api:mono_free_method">mono_free_method</a></h4>
|
||||
<h4><a name="api:mono_free_verify_list">mono_free_verify_list</a></h4>
|
||||
<h4><a name="api:mono_get_config_dir">mono_get_config_dir</a></h4>
|
||||
@@ -13,8 +15,13 @@
|
||||
<h4><a name="api:mono_get_method_full">mono_get_method_full</a></h4>
|
||||
<h4><a name="api:mono_get_method">mono_get_method</a></h4>
|
||||
<h4><a name="api:mono_get_root_domain">mono_get_root_domain</a></h4>
|
||||
<h4><a name="api:mono_init_from_assembly">mono_init_from_assembly</a></h4>
|
||||
<h4><a name="api:mono_init">mono_init</a></h4>
|
||||
<h4><a name="api:mono_init_version">mono_init_version</a></h4>
|
||||
<h4><a name="api:mono_jit_exec">mono_jit_exec</a></h4>
|
||||
<h4><a name="api:mono_lookup_internal_call">mono_lookup_internal_call</a></h4>
|
||||
<h4><a name="api:mono_lookup_pinvoke_call">mono_lookup_pinvoke_call</a></h4>
|
||||
<h4><a name="api:mono_main">mono_main</a></h4>
|
||||
<h4><a name="api:mono_parse_default_optimizations">mono_parse_default_optimizations</a></h4>
|
||||
<h4><a name="api:mono_ptr_class_get">mono_ptr_class_get</a></h4>
|
||||
<h4><a name="api:mono_register_bundled_assemblies">mono_register_bundled_assemblies</a></h4>
|
||||
@@ -27,4 +34,6 @@
|
||||
<h4><a name="api:mono_runtime_quit">mono_runtime_quit</a></h4>
|
||||
<h4><a name="api:mono_runtime_run_main">mono_runtime_run_main</a></h4>
|
||||
<h4><a name="api:mono_table_info_get_rows">mono_table_info_get_rows</a></h4>
|
||||
<h4><a name="api:mono_upgrade_remote_class_wrapper">mono_upgrade_remote_class_wrapper</a></h4>
|
||||
<h4><a name="api:mono_verify_corlib">mono_verify_corlib</a></h4>
|
||||
<h4><a name="api:mono_vtable_get_static_field_data">mono_vtable_get_static_field_data</a></h4>
|
||||
@@ -1,5 +1,111 @@
|
||||
<h2>Utility Methods</h2>
|
||||
|
||||
<h3>Bitsets</h3>
|
||||
|
||||
<p>MonoBitsets are a set of routines used to manipulate sets
|
||||
of bits.
|
||||
|
||||
<h4><a name="api:mono_bitset_alloc_size">mono_bitset_alloc_size</a></h4>
|
||||
<h4><a name="api:mono_bitset_clear">mono_bitset_clear</a></h4>
|
||||
<h4><a name="api:mono_bitset_clear_all">mono_bitset_clear_all</a></h4>
|
||||
<h4><a name="api:mono_bitset_clone">mono_bitset_clone</a></h4>
|
||||
<h4><a name="api:mono_bitset_copyto">mono_bitset_copyto</a></h4>
|
||||
<h4><a name="api:mono_bitset_count">mono_bitset_count</a></h4>
|
||||
<h4><a name="api:mono_bitset_equal">mono_bitset_equal</a></h4>
|
||||
<h4><a name="api:mono_bitset_find_first">mono_bitset_find_first</a></h4>
|
||||
<h4><a name="api:mono_bitset_find_last">mono_bitset_find_last</a></h4>
|
||||
<h4><a name="api:mono_bitset_find_start">mono_bitset_find_start</a></h4>
|
||||
<h4><a name="api:mono_bitset_foreach">mono_bitset_foreach</a></h4>
|
||||
<h4><a name="api:mono_bitset_free">mono_bitset_free</a></h4>
|
||||
<h4><a name="api:mono_bitset_intersection">mono_bitset_intersection</a></h4>
|
||||
<h4><a name="api:mono_bitset_invert">mono_bitset_invert</a></h4>
|
||||
<h4><a name="api:mono_bitset_mem_new">mono_bitset_mem_new</a></h4>
|
||||
<h4><a name="api:mono_bitset_new">mono_bitset_new</a></h4>
|
||||
<h4><a name="api:mono_bitset_set">mono_bitset_set</a></h4>
|
||||
<h4><a name="api:mono_bitset_set_all">mono_bitset_set_all</a></h4>
|
||||
<h4><a name="api:mono_bitset_size">mono_bitset_size</a></h4>
|
||||
<h4><a name="api:mono_bitset_sub">mono_bitset_sub</a></h4>
|
||||
<h4><a name="api:mono_bitset_test">mono_bitset_test</a></h4>
|
||||
<h4><a name="api:mono_bitset_test_bulk">mono_bitset_test_bulk</a></h4>
|
||||
<h4><a name="api:mono_bitset_union">mono_bitset_union</a></h4>
|
||||
<h4><a name="api:mono_bitset_find_first_unset">mono_bitset_find_first_unset</a></h4>
|
||||
<h4><a name="api:mono_bitset_intersection_2">mono_bitset_intersection_2</a></h4>
|
||||
|
||||
<h3>Hashtables</h3>
|
||||
|
||||
<p><tt>GHashTable</tt> is used when you need to store object
|
||||
references into a hashtable, objects stored in a
|
||||
<tt>MonoGHashTable</tt> are properly tracked by the garbage
|
||||
collector.
|
||||
|
||||
<p>The <tt>MonoGHashTable</tt> data type has the same API as
|
||||
the GLIB.
|
||||
|
||||
<h4><a name="api:mono_g_hash_table_destroy">mono_g_hash_table_destroy</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_foreach">mono_g_hash_table_foreach</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_foreach_remove">mono_g_hash_table_foreach_remove</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_foreach_steal">mono_g_hash_table_foreach_steal</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_insert">mono_g_hash_table_insert</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_lookup">mono_g_hash_table_lookup</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_lookup_extended">mono_g_hash_table_lookup_extended</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_new">mono_g_hash_table_new</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_new_full">mono_g_hash_table_new_full</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_remap">mono_g_hash_table_remap</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_remove">mono_g_hash_table_remove</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_replace">mono_g_hash_table_replace</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_size">mono_g_hash_table_size</a></h4>
|
||||
<h4><a name="api:mono_g_hash_table_steal">mono_g_hash_table_steal</a></h4>
|
||||
|
||||
<h3>SHA1 Signatures</h3>
|
||||
|
||||
<h4><a name="api:mono_sha1_init">mono_sha1_init</a></h4>
|
||||
<h4><a name="api:mono_sha1_update">mono_sha1_update</a></h4>
|
||||
<h4><a name="api:mono_sha1_get_digest_from_file">mono_sha1_get_digest_from_file</a></h4>
|
||||
<h4><a name="api:mono_sha1_get_digest">mono_sha1_get_digest</a></h4>
|
||||
<h4><a name="api:mono_sha1_final">mono_sha1_final</a></h4>
|
||||
|
||||
<h3>MD5 Signatures</h3>
|
||||
|
||||
<h4><a name="api:mono_md5_init">mono_md5_init</a></h4>
|
||||
<h4><a name="api:mono_md5_update">mono_md5_update</a></h4>
|
||||
<h4><a name="api:mono_md5_get_digest_from_file">mono_md5_get_digest_from_file</a></h4>
|
||||
<h4><a name="api:mono_md5_get_digest">mono_md5_get_digest</a></h4>
|
||||
<h4><a name="api:mono_md5_final">mono_md5_final</a></h4>
|
||||
|
||||
<h4><a name="api:mono_digest_get_public_token">mono_digest_get_public_token</a></h4>
|
||||
|
||||
<h3>Memory Pools</h3>
|
||||
|
||||
<p>Memory pools are a convenient way of tracking memory
|
||||
allocations that are used for one specific task, they are also
|
||||
faster than using the standard memory allocation procedures,
|
||||
as they are designed to be used only by a single thread at a
|
||||
time.
|
||||
|
||||
<p><tt>MonoMemPool</tt> objects are not thread safe, which
|
||||
means that you should not share the objects across multiple
|
||||
threads without providing proper locking around it (unlike
|
||||
<tt>malloc</tt> and <tt>free</tt> which are thread safe).
|
||||
|
||||
<p>When a <tt>MonoMemPool</tt> is released with
|
||||
<tt>mono_mempool_destroy</tt> all of the of the memory
|
||||
allocated from that memory pool with
|
||||
<tt>mono_mempool_alloc</tt> and <tt>mono_mempool_alloc0</tt>
|
||||
is released.
|
||||
|
||||
<h4><a name="api:mono_mempool_new">mono_mempool_new</a></h4>
|
||||
<h4><a name="api:mono_mempool_destroy">mono_mempool_destroy</a></h4>
|
||||
<h4><a name="api:mono_mempool_alloc">mono_mempool_alloc</a></h4>
|
||||
<h4><a name="api:mono_mempool_alloc0">mono_mempool_alloc0</a></h4>
|
||||
<h4><a name="api:mono_mempool_empty">mono_mempool_empty</a></h4>
|
||||
<h4><a name="api:mono_mempool_invalidate">mono_mempool_invalidate</a></h4>
|
||||
<h4><a name="api:mono_mempool_stats">mono_mempool_stats</a></h4>
|
||||
<h4><a name="api:mono_mempool_contains_addr">mono_mempool_contains_addr</a></h4>
|
||||
|
||||
<h3>JIT utilities</h3>
|
||||
|
||||
<h4><a name="api:mono_signbit_double">mono_signbit_double</a></h4>
|
||||
<h4><a name="api:mono_signbit_float">mono_signbit_float</a></h4>
|
||||
|
||||
<h3>Disassembling Generated Code</h3>
|
||||
|
||||
@@ -10,10 +116,11 @@
|
||||
|
||||
<h3>Walking the Stack</h3>
|
||||
|
||||
<h4><a name="api:mono_walk_stack">mono_walk_stack</a></h4>
|
||||
<h4><a name="api:mono_stack_walk_no_il">mono_stack_walk_no_il</a></h4>
|
||||
<h4><a name="api:mono_stack_walk_async_safe">mono_stack_walk_async_safe</a></h4>
|
||||
|
||||
<h3>Others</h3>
|
||||
|
||||
<h4><a name="api:mono_escape_uri_string">mono_escape_uri_string</a></h4>
|
||||
<h4><a name="api:mono_guid_to_string">mono_guid_to_string</a></h4>
|
||||
|
||||
@@ -0,0 +1,33 @@
|
||||
Size and alignment requirements of stack values
|
||||
===============================================
|
||||
|
||||
P ... System.IntPtr
|
||||
I1 ... System.Int8
|
||||
I2 ... System.Int16
|
||||
I4 ... System.Int32
|
||||
I8 ... System.Int64
|
||||
F ... System.Single
|
||||
D ... System.Double
|
||||
LD ... native long double
|
||||
|
||||
-----------------------------------------------------------
|
||||
ARCH | P | I1 | I2 | I4 | I8 | F | D | LD |
|
||||
-----------------------------------------------------------
|
||||
X86 | 4/4 | 4/4 | 4/4 | 4/4 | 8/4 | 4/4 | 8/4 |12/4 |
|
||||
-----------------------------------------------------------
|
||||
X86/W32 | 4/4 | 4/4 | 4/4 | 4/4 | 8/4 | 4/4 | 8/4 |12/4 |
|
||||
-----------------------------------------------------------
|
||||
ARM | 4/4 | 4/4 | 4/4 | 4/4 | 8/4 | 4/4 | 8/4 | 8/4 |
|
||||
-----------------------------------------------------------
|
||||
M68K | 4/4 | 4/4 | 4/4 | 4/4 | 8/4 | 4/4 | 8/4 |12/4 |
|
||||
-----------------------------------------------------------
|
||||
ALPHA | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 |
|
||||
-----------------------------------------------------------
|
||||
SPARC | 4/4 | 4/4 | 4/4 | 4/4 | 8/8 | 4/4 | 8/8 |16/8 |
|
||||
-----------------------------------------------------------
|
||||
SPARC64 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 |16/16|
|
||||
-----------------------------------------------------------
|
||||
MIPS | 4/4 | 4/4 | 4/4 | 4/4 | ?/? | 4/4 | 8/8 | 8/8 |
|
||||
-----------------------------------------------------------
|
||||
| | | | | | | | |
|
||||
-----------------------------------------------------------
|
||||
+36
-18
@@ -12,12 +12,6 @@
|
||||
<param name="Local" value="DoesNotExist"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Embedding Mono"/>
|
||||
<param name="Local" value="deploy/mono-api-embedding.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Assemblies"/>
|
||||
@@ -54,12 +48,30 @@
|
||||
<param name="Local" value="deploy/mono-api-class.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Code Generation"/>
|
||||
<param name="Local" value="deploy/mono-api-codegen.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Decimal Representation"/>
|
||||
<param name="Local" value="deploy/mono-api-decimal.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Application Domains"/>
|
||||
<param name="Local" value="deploy/mono-api-domains.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Dynamic Code Generation"/>
|
||||
<param name="Local" value="deploy/mono-api-dynamic-codegen.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Exceptions"/>
|
||||
@@ -78,12 +90,24 @@
|
||||
<param name="Local" value="deploy/mono-api-gc.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Embedding Mono"/>
|
||||
<param name="Local" value="deploy/mono-api-embedding.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Just in Time Compiler"/>
|
||||
<param name="Local" value="deploy/mono-api-jit.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Marshalling"/>
|
||||
<param name="Local" value="deploy/mono-api-marshal.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Metadata access"/>
|
||||
@@ -116,6 +140,12 @@
|
||||
</object>
|
||||
</li>
|
||||
-->
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="JIT Counters"/>
|
||||
<param name="Local" value="deploy/mono-api-counters.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Types"/>
|
||||
@@ -152,24 +182,12 @@
|
||||
<param name="Local" value="deploy/mono-api-utils.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="JIT Counters"/>
|
||||
<param name="Local" value="deploy/mono-api-counters.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Unsorted"/>
|
||||
<param name="Local" value="deploy/mono-api-unsorted.html"/>
|
||||
</object>
|
||||
</li>
|
||||
<li>
|
||||
<object type="text/sitemap">
|
||||
<param name="Name" value="Internal: Dynamic Code Generation"/>
|
||||
<param name="Local" value="deploy/mono-api-dynamic-codegen.html"/>
|
||||
</object>
|
||||
</li>
|
||||
</ul>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,261 @@
|
||||
|
||||
Purpose
|
||||
|
||||
Especially when inlining is active, it can happen that temporary
|
||||
variables add pressure to the register allocator, producing bad
|
||||
code.
|
||||
|
||||
The idea is that some of these temporaries can be totally eliminated
|
||||
my moving the MonoInst tree that defines them directly to the use
|
||||
point in the code (so the name "tree mover").
|
||||
|
||||
Please note that this is *not* an optimization: it is mostly a
|
||||
workaround to issues we have in the regalloc.
|
||||
Actually, with the new linear IR this will not be possible at all
|
||||
(there will be no more trees in the code!).
|
||||
Anyway, this workaround turns out to be useful in the current state
|
||||
of things...
|
||||
|
||||
-----------------------------------------------------------------------
|
||||
|
||||
Base logic
|
||||
|
||||
If a local is defined by a value which is a proper expression (a tree
|
||||
of MonoInst, not just another local or a constant), and this definition
|
||||
is used only once, the tree can be moved directly to the use location,
|
||||
and the definition eliminated.
|
||||
Of course, none of the variables used in the tree must be defined in
|
||||
the code path between the definition and the use, and the tree must be
|
||||
free of side effects.
|
||||
We do not handle the cases when the tree is just a local or a constant
|
||||
because they are handled by copyprop and consprop, respectively.
|
||||
|
||||
To make things simpler, we restrict the tree move to the case when:
|
||||
- the definition and the use are in the same BB, and
|
||||
- the use is followed by another definition in the same BB (it is not
|
||||
possible that the 1st value is used again), or alternatively there
|
||||
is no BB in the whole CFG that contains a use of this local before a
|
||||
definition (so, again, there is no code path that can lead to a
|
||||
subsequent use).
|
||||
|
||||
To handle this, we maintain an ACT array (Available Copy Tree, similar
|
||||
to the ACP), where we store the "state" of every local.
|
||||
Ideally, every local can be in the following state:
|
||||
[E] Undefined (by a tree, it could be in the ACP but we don't care).
|
||||
[D] Defined (by a tree), and waiting for a use.
|
||||
[U] Used, with a tree definition available in the same BB, but still
|
||||
without a definition following the use (always in the same BB).
|
||||
Of course state [E] (empty) is the initial one.
|
||||
|
||||
Besides, there are two sort of "meta states", or flags:
|
||||
[W] Still waiting for a use or definition in this BB (we have seen no
|
||||
occurrence of the local yet).
|
||||
[X] Used without being previously defined in the same BB (note that if
|
||||
there is a definition that precedes the use in the same BB, even if
|
||||
the definition is not a tree or is not available because of side
|
||||
effects or because the tree value has changed the local is not in
|
||||
state [X]).
|
||||
Also note that state [X] is a sort of "global" condition, which if set
|
||||
in one BB will stay valid for the whole CFG, even if the local will
|
||||
otherwise change state. The idea of flagging a local as [X] is that if
|
||||
there is a definition/use pair that reaches the end of a BB, it could
|
||||
be that there is a CFG path that then leads to the BB flagging it as
|
||||
[X] (which contains a use), so the tree cannot be moved.
|
||||
So state [X] will always be set, and never examined in all the state
|
||||
transitions we will describe.
|
||||
In practice, we use flag [W] to set state [X]: if, when traversing a
|
||||
BB, we find a use for a local in state [W], then that local is flagged
|
||||
[X].
|
||||
|
||||
|
||||
For each BB, we initialize all states to [E] and [W], and then we
|
||||
traverse the code one inst at a time, and update the variable states
|
||||
in the ACT in the following ways:
|
||||
|
||||
[Definition]
|
||||
- Flag [W] is cleared.
|
||||
- All "affected trees" are killed (go from state [D] to [E]).
|
||||
The "affected trees" are the trees which contain (use) the defined
|
||||
local, and the rationale is that the tree value changed, so the
|
||||
tree is no longer available.
|
||||
- If the local was in state [U], *that* tree move is marked "safe"
|
||||
(because *this* definition makes us sure that the previous tree
|
||||
cannot be used again in any way).
|
||||
The idea is that "safe" moves can happen even if the local is
|
||||
flagged [X], because the second definition "covers" the use.
|
||||
The tree move is then saved in the "todo" list (and the affecting
|
||||
nodes are cleared).
|
||||
- If the local was defined by a tree, it goes to state [D], the tree
|
||||
is recorded, and all the locals used in it are marked as "affecting
|
||||
this tree" (of course these markers are lists, because each local
|
||||
could affect more than one tree).
|
||||
|
||||
[IndirectDefinition]
|
||||
- All potentially affected trees (in state [D]) are killed.
|
||||
|
||||
[Use]
|
||||
- If the local is still [W], it is flagged [X] (the [W] goes away).
|
||||
- If the local is in state [D], it goes to state [U].
|
||||
The tree move must not yet be recorded in the "todo" list, it still
|
||||
stays in the ACT slot belonging to this local.
|
||||
Anyway, the "affecting" nodes are updated, because now a definition
|
||||
of a local used in this tree will affect only "indirect" (or also
|
||||
"propagated") moves, but not *this* move (see below).
|
||||
- If the local is in state [U], then the tree cannot be moved (it is
|
||||
used two times): the move is canceled, and the state goes [E].
|
||||
- If the local is in state [E], the use is ignored.
|
||||
|
||||
[IndirectUse]
|
||||
- All potentially affected trees (in state [D] or [U]) are killed.
|
||||
|
||||
[SideEffect]
|
||||
- Tree is marked as "unmovable".
|
||||
|
||||
Then, at the end of the BB, for each ACT slot:
|
||||
- If state is [U], the tree move is recorded in the "todo" list, but
|
||||
flagged "unsafe".
|
||||
- Anyway, state goes to [E], the [W] flag is set, and all "affecting"
|
||||
lists are cleared (we get ready to traverse the next BB).
|
||||
Finally, when all BBs has been scanned, we traverse the "todo" list,
|
||||
moving all "safe" entries, and moving "unsafe" ones only if their ACT
|
||||
slot is not flagged [X].
|
||||
|
||||
So far, so good.
|
||||
But there are two issues that make things harder :-(
|
||||
|
||||
The first is the concept of "indirect tree move".
|
||||
It can happen that a tree is scheduled for moving, and its destination
|
||||
is a use that is located in a second tree, which could also be moved.
|
||||
The main issue is that a definition of a variable of the 1st tree on
|
||||
the path between the definition and the use of the 2nd one must prevent
|
||||
the move.
|
||||
But which move? The 1st or the 2nd?
|
||||
Well, any of the two!
|
||||
The point is, the 2nd move must be prevented *only* if the 1st one
|
||||
happens: if it is aborted (for an [X] flag or any other reason), the
|
||||
2nd move is OK, and vice versa...
|
||||
We must handle this in the following way:
|
||||
- The ACT must still remember if a slot is scheduled for moving in
|
||||
this BB, and if it is, all the locals used in the tree.
|
||||
We say that the slot is in state [M].
|
||||
Note that [M] is (like [X] and [W]) a sort of "meta state": a local
|
||||
is flagged [M] when it goes to state [U], and the flag is cleared
|
||||
when the tree move is cancelled
|
||||
- A tree that uses a local whose slot is in state [M] is also using all
|
||||
the locals used by the tree in state [M], but the use is "indirect".
|
||||
These use nodes are also included in the "affecting" lists.
|
||||
- The definition of a variable used in an "indirect" way has the
|
||||
effect of "linking" the two involved tree moves, saying that only one
|
||||
of the two can happen in practice, but not both.
|
||||
- When the 2nd tree is scheduled for moving, the 1st one is *still* in
|
||||
state [M], because a third move could "carry it forward", and all the
|
||||
*three* moves should be mutually exclusive (to be safe!).
|
||||
|
||||
The second tricky complication is the "tree forwarding" that can happen
|
||||
when copyprop is involved.
|
||||
It is conceptually similar to the "indirect tree move".
|
||||
Only, the 2nd tree is not really a tree, it is just the local defined
|
||||
in the 1st tree move.
|
||||
It can happen that copyprop will propagate the definition.
|
||||
We cannot make treeprop do the same job of copyprop, because copyprop
|
||||
has less constraints, and is therefore more powerful in its scope.
|
||||
The main issue is that treeprop cannot propagate a tree to *two* uses,
|
||||
while copyprop is perfectly capable of propagating one definition to
|
||||
two (or more) different places.
|
||||
So we must let copyprop do its job otherwise we'll miss optimizations,
|
||||
but we must also make it play safe with treeprop.
|
||||
Let's clarify with an example:
|
||||
a = v1 + v2; //a is defined by a tree, state [D], uses v2 and v2
|
||||
b = a; //a is used, state [U] with move scheduled, and
|
||||
//b is defined by a, ACP[b] is a, and b is in state [DC]
|
||||
c = b + v3; // b is used, goes to state [U]
|
||||
The real trouble is that copyprop happens *immediately*, while treeprop
|
||||
is deferred to the end of the CFG traversal.
|
||||
So, in the 3rd statement, the "b" is immediately turned into an "a" by
|
||||
copyprop, regardless of what treeprop will do.
|
||||
Anyway, if we are careful, this is not so bad.
|
||||
First of all, we must "accept" the fact that in the 3rd statement the
|
||||
"b" is in fact an "a", as treeprop must happen *after* copyprop.
|
||||
The real problem is that "a" is used twice: in the 2nd and 3rd lines.
|
||||
In our usual setup, the 2nd line would set it to [U], and the 3rd line
|
||||
would kill the move (and set "a" to [E]).
|
||||
I have tried to play tricks, and reason as of copyprop didn't happen,
|
||||
but everything becomes really messy.
|
||||
Instead, we should note that the 2nd line is very likely to be dead.
|
||||
At least in this BB, copyprop will turn all "b"s into "a"s as long as
|
||||
it can, and when it cannot, it will be because either "a" or "b" have
|
||||
been redefined, which would be after the tree move anyway.
|
||||
So, the reasoning gets different: let's pretend that "b" will be dead.
|
||||
This will make the "a" use in the 2nd statement useless, so there we
|
||||
can "reset" "a" to [D], but also take note that if "b" will end up
|
||||
not being dead, the tree move associated to this [D] must be aborted.
|
||||
We can detect this in the following way:
|
||||
- Either "b" is used before being defined in this BB, or
|
||||
- It will be flagged "unsafe".
|
||||
Both things are very easy to check.
|
||||
The only quirk is that the "affecting" lists must not be cleared when
|
||||
a slot goes to state [U], because a "propagation" could put it back
|
||||
to state [D] (where those lists are needed, because it can be killed
|
||||
by a definition to a used slot).
|
||||
|
||||
-----------------------------------------------------------------------
|
||||
|
||||
Implementation notes
|
||||
|
||||
All the implementation runs inside the existing mono_local_cprop
|
||||
function, and a separate memory pool is used to hold the temporary
|
||||
data.
|
||||
|
||||
A struct, MonoTreeMover, contains the pointers to the pool, the ACT,
|
||||
the list of scheduled moves and auxiliary things.
|
||||
This struct is allocated if the tree move pass is requested, and is
|
||||
then passed along to all the involved functions, which are therefore
|
||||
aware of the tree mover state.
|
||||
|
||||
The ACT is an array of slots, obviously one per local.
|
||||
Each slot is of type MonoTreeMoverActSlot, and contains the used and
|
||||
affected locals, a pointer to the pending tree move and the "waiting"
|
||||
and "unsafe" flags.
|
||||
|
||||
The "affecting" lists a built from "dependency nodes", of type
|
||||
MonoTreeMoverDependencyNode.
|
||||
Each of the nodes contains the used and affected local, and is in
|
||||
two lists: the locals used by a slot, and the locals affected by a
|
||||
slot (obviously a different one).
|
||||
So, each node means: "variable x is used in tree t, so a definition
|
||||
of x affects tree t".
|
||||
The "affecting" lists are doubly linked, to allow for O(1) deletion.
|
||||
The "used" lists are simply linked, but when they are mantained there
|
||||
is always a pointer to the last element to allow for O(1) list moving.
|
||||
When a used list is dismissed (which happens often, any time a node is
|
||||
killed), its nodes are unlinked from their respective affecting lists
|
||||
and are then put in a "free" list in the MonoTreeMover to be reused.
|
||||
|
||||
Each tree move is represented by a struct (MonoTreeMoverTreeMove),
|
||||
which contains:
|
||||
- the definition and use points,
|
||||
- the "affected" moves (recall the concept of "indirect tree move"),
|
||||
- the "must be dead" slots (recall "tree forwarding"). and
|
||||
- a few utility flags.
|
||||
The tree moves stays in the relevant ACT slot until it is ready to be
|
||||
scheduled for moving, at which point it is put in a list in the
|
||||
MonoTreeMover.
|
||||
The tree moves structs are reused when they are killed, so there is
|
||||
also a "free" list for them in the MonoTreeMover.
|
||||
|
||||
The tree mover code has been added to all the relevant functions that
|
||||
participate in consprop and copyprop, particularly:
|
||||
- mono_cprop_copy_values takes care of variable uses (transitions from
|
||||
states [D] to [U] and [U] to [E] because of killing),
|
||||
- mono_cprop_invalidate_values takes care of side effects (indirect
|
||||
accesses, calls...),
|
||||
- mono_local_cprop_bb sets up and cleans the traversals for each BB,
|
||||
and for each MonoInst it takes care of variable definitions.
|
||||
To each of them has been added a MonoTreeMover parameter, which is not
|
||||
NULL if the tree mover is running.
|
||||
After mono_local_cprop_bb has run for all BBs, the MonoTreeMover has
|
||||
the list of all the pending moves, which must be walked to actually
|
||||
perform the moves (when possible, because "unsafe" flags, "affected"
|
||||
moves and "must be dead" slots can still have their effects, which
|
||||
must be handled now because they are fully known only at the end of
|
||||
the CFG traversal).
|
||||
+1564
File diff suppressed because it is too large.
Load diff
+1
-1
@@ -16,4 +16,4 @@ endif
|
||||
endif
|
||||
endif
|
||||
|
||||
EXTRA_DIST = autogen.sh README NEWS AUTHORS winconfig.h
|
||||
EXTRA_DIST = autogen.sh README NEWS AUTHORS ChangeLog winconfig.h
|
||||
+8
-8
@@ -30,18 +30,18 @@ fi
|
||||
DIE=1
|
||||
}
|
||||
|
||||
if [ -z "$LIBTOOLIZE" ]; then
|
||||
LIBTOOLIZE=`which glibtoolize 2>/dev/null`
|
||||
if [ ! -x "$LIBTOOLIZE" ]; then
|
||||
LIBTOOLIZE=`which libtoolize`
|
||||
if [ -z "$LIBTOOL" ]; then
|
||||
LIBTOOL=`which glibtool 2>/dev/null`
|
||||
if [ ! -x "$LIBTOOL" ]; then
|
||||
LIBTOOL=`which libtool`
|
||||
fi
|
||||
fi
|
||||
|
||||
(grep "^AM_PROG_LIBTOOL" $srcdir/configure.ac >/dev/null) && {
|
||||
($LIBTOOLIZE --version) < /dev/null > /dev/null 2>&1 || {
|
||||
($LIBTOOL --version) < /dev/null > /dev/null 2>&1 || {
|
||||
echo
|
||||
echo "**Error**: You must have \`libtoolize' installed to compile Mono."
|
||||
echo "Get ftp://ftp.gnu.org/gnu/libtool/libtool-1.2.tar.gz"
|
||||
echo "**Error**: You must have \`libtool' installed to compile Mono."
|
||||
echo "Get ftp://ftp.gnu.org/pub/gnu/libtool-1.2d.tar.gz"
|
||||
echo "(or a newer version if it is available)"
|
||||
DIE=1
|
||||
}
|
||||
@@ -98,7 +98,7 @@ esac
|
||||
if grep "^AM_PROG_LIBTOOL" configure.ac >/dev/null; then
|
||||
if test -z "$NO_LIBTOOLIZE" ; then
|
||||
echo "Running libtoolize..."
|
||||
$LIBTOOLIZE --force --copy
|
||||
${LIBTOOL}ize --force --copy
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
+1
-3
@@ -136,7 +136,6 @@ AC_CHECK_SIZEOF(long)
|
||||
AC_CHECK_SIZEOF(long long)
|
||||
AC_CHECK_FUNCS(strlcpy stpcpy strtok_r rewinddir vasprintf)
|
||||
AC_CHECK_FUNCS(getrlimit)
|
||||
AC_CHECK_FUNCS(fork execv execve)
|
||||
|
||||
#
|
||||
# Mono currently supports 10.6, but strndup is not available prior to 10.7; avoiding
|
||||
@@ -151,7 +150,7 @@ elif test x$target_ios = xno; then
|
||||
AC_CHECK_FUNCS(strndup getpwuid_r)
|
||||
fi
|
||||
|
||||
AM_CONDITIONAL(NEED_VASPRINTF, test x$ac_cv_func_vasprintf = xno )
|
||||
AM_CONDITIONAL(NEED_VASPRINTF, test x$have_vasprintf = x )
|
||||
AM_ICONV()
|
||||
AC_SEARCH_LIBS(sqrtf, m)
|
||||
|
||||
@@ -182,7 +181,6 @@ fi
|
||||
AC_SUBST(G_HAVE_ISO_VARARGS)
|
||||
|
||||
AC_CHECK_HEADERS(getopt.h sys/select.h sys/time.h sys/wait.h pwd.h langinfo.h iconv.h localcharset.h sys/types.h sys/resource.h)
|
||||
AC_CHECK_LIB([iconv], [locale_charset],[],[AC_CHECK_LIB([charset], [locale_charset],[LIBS+="-liconv -lcharset"])])
|
||||
AC_CHECK_HEADER(alloca.h, [HAVE_ALLOCA_H=1], [HAVE_ALLOCA_H=0])
|
||||
AC_SUBST(HAVE_ALLOCA_H)
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
noinst_LTLIBRARIES = libeglib.la
|
||||
noinst_LTLIBRARIES = libeglib.la libeglib-static.la
|
||||
|
||||
AM_CFLAGS = $(WERROR_CFLAGS)
|
||||
|
||||
@@ -59,6 +59,8 @@ libeglib_la_SOURCES = \
|
||||
$(vasprintf_files)
|
||||
|
||||
libeglib_la_CFLAGS = -g -Wall -D_FORTIFY_SOURCE=2
|
||||
libeglib_static_la_SOURCES=$(libeglib_la_SOURCES)
|
||||
libeglib_static_la_CFLAGS = $(libeglib_la_CFLAGS)
|
||||
|
||||
AM_CPPFLAGS = -I$(srcdir)
|
||||
|
||||
@@ -70,6 +72,9 @@ libeglib_la_LIBADD = -llog
|
||||
endif
|
||||
endif
|
||||
|
||||
libeglib_static_la_LIBADD = $(libeglib_la_LIBADD) $(LIBICONV)
|
||||
libeglib_static_la_LDFLAGS = -static
|
||||
|
||||
MAINTAINERCLEANFILES = Makefile.in
|
||||
|
||||
EXTRA_DIST = eglib-config.h.in $(win_files) $(unix_files)
|
||||
@@ -36,7 +36,7 @@ typedef signed @GSIZE@ gssize;
|
||||
#define G_HAVE_ISO_VARARGS
|
||||
#endif
|
||||
|
||||
#if defined (__native_client__) || defined (HOST_WATCHOS)
|
||||
#if defined (__native_client__)
|
||||
#undef G_BREAKPOINT
|
||||
#define G_BREAKPOINT()
|
||||
#endif
|
||||
|
||||
@@ -49,10 +49,3 @@ g_byte_array_append (GByteArray *array,
|
||||
{
|
||||
return (GByteArray *)g_array_append_vals ((GArray *)array, data, len);
|
||||
}
|
||||
|
||||
void
|
||||
g_byte_array_set_size (GByteArray *array, gint length)
|
||||
{
|
||||
g_array_set_size ((GArray *)array, length);
|
||||
}
|
||||
|
||||
@@ -58,7 +58,7 @@ int mkstemp (char *tmp_template)
|
||||
utf16_template = _wmktemp( utf16_template);
|
||||
if (utf16_template && *utf16_template) {
|
||||
/* FIXME: _O_TEMPORARY causes file to disappear on close causing a test to fail */
|
||||
fd = _wopen( utf16_template, _O_BINARY | _O_CREAT /*| _O_TEMPORARY*/ | _O_RDWR | _O_EXCL, _S_IREAD | _S_IWRITE);
|
||||
fd = _wopen( utf16_template, _O_BINARY | _O_CREAT /*| _O_TEMPORARY*/ | _O_EXCL, _S_IREAD | _S_IWRITE);
|
||||
}
|
||||
|
||||
/* FIXME: this will crash if utf16_template == NULL */
|
||||
|
||||
+35
-2
@@ -777,9 +777,42 @@ g_convert (const gchar *str, gssize len, const gchar *to_charset, const gchar *f
|
||||
*/
|
||||
|
||||
/**
|
||||
* An explanation of the conversion can be found at:
|
||||
* http://home.tiscali.nl/t876506/utf8tbl.html
|
||||
* from http://home.tiscali.nl/t876506/utf8tbl.html
|
||||
*
|
||||
* From Unicode UCS-4 to UTF-8:
|
||||
* Start with the Unicode number expressed as a decimal number and call this ud.
|
||||
*
|
||||
* If ud <128 (7F hex) then UTF-8 is 1 byte long, the value of ud.
|
||||
*
|
||||
* If ud >=128 and <=2047 (7FF hex) then UTF-8 is 2 bytes long.
|
||||
* byte 1 = 192 + (ud div 64)
|
||||
* byte 2 = 128 + (ud mod 64)
|
||||
*
|
||||
* If ud >=2048 and <=65535 (FFFF hex) then UTF-8 is 3 bytes long.
|
||||
* byte 1 = 224 + (ud div 4096)
|
||||
* byte 2 = 128 + ((ud div 64) mod 64)
|
||||
* byte 3 = 128 + (ud mod 64)
|
||||
*
|
||||
* If ud >=65536 and <=2097151 (1FFFFF hex) then UTF-8 is 4 bytes long.
|
||||
* byte 1 = 240 + (ud div 262144)
|
||||
* byte 2 = 128 + ((ud div 4096) mod 64)
|
||||
* byte 3 = 128 + ((ud div 64) mod 64)
|
||||
* byte 4 = 128 + (ud mod 64)
|
||||
*
|
||||
* If ud >=2097152 and <=67108863 (3FFFFFF hex) then UTF-8 is 5 bytes long.
|
||||
* byte 1 = 248 + (ud div 16777216)
|
||||
* byte 2 = 128 + ((ud div 262144) mod 64)
|
||||
* byte 3 = 128 + ((ud div 4096) mod 64)
|
||||
* byte 4 = 128 + ((ud div 64) mod 64)
|
||||
* byte 5 = 128 + (ud mod 64)
|
||||
*
|
||||
* If ud >=67108864 and <=2147483647 (7FFFFFFF hex) then UTF-8 is 6 bytes long.
|
||||
* byte 1 = 252 + (ud div 1073741824)
|
||||
* byte 2 = 128 + ((ud div 16777216) mod 64)
|
||||
* byte 3 = 128 + ((ud div 262144) mod 64)
|
||||
* byte 4 = 128 + ((ud div 4096) mod 64)
|
||||
* byte 5 = 128 + ((ud div 64) mod 64)
|
||||
* byte 6 = 128 + (ud mod 64)
|
||||
**/
|
||||
gint
|
||||
g_unichar_to_utf8 (gunichar c, gchar *outbuf)
|
||||
|
||||
@@ -486,7 +486,6 @@ struct _GByteArray {
|
||||
GByteArray *g_byte_array_new (void);
|
||||
GByteArray* g_byte_array_append (GByteArray *array, const guint8 *data, guint len);
|
||||
guint8* g_byte_array_free (GByteArray *array, gboolean free_segment);
|
||||
void g_byte_array_set_size (GByteArray *array, gint length);
|
||||
|
||||
/*
|
||||
* Array
|
||||
|
||||
+10
-15
@@ -93,29 +93,24 @@ get_pw_data (void)
|
||||
pthread_mutex_unlock (&pw_lock);
|
||||
return;
|
||||
}
|
||||
|
||||
home_dir = g_getenv ("HOME");
|
||||
user_name = g_getenv ("USER");
|
||||
|
||||
#ifdef HAVE_GETPWUID_R
|
||||
if (home_dir == NULL || user_name == NULL) {
|
||||
if (getpwuid_r (getuid (), &pw, buf, 4096, &result) == 0) {
|
||||
if (home_dir == NULL)
|
||||
home_dir = g_strdup (pw.pw_dir);
|
||||
if (user_name == NULL)
|
||||
user_name = g_strdup (pw.pw_name);
|
||||
}
|
||||
if (getpwuid_r (getuid (), &pw, buf, 4096, &result) == 0) {
|
||||
home_dir = g_strdup (pw.pw_dir);
|
||||
user_name = g_strdup (pw.pw_name);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (user_name == NULL)
|
||||
user_name = "somebody";
|
||||
if (home_dir == NULL)
|
||||
home_dir = "/";
|
||||
home_dir = g_getenv ("HOME");
|
||||
|
||||
if (user_name == NULL) {
|
||||
user_name = g_getenv ("USER");
|
||||
if (user_name == NULL)
|
||||
user_name = "somebody";
|
||||
}
|
||||
pthread_mutex_unlock (&pw_lock);
|
||||
}
|
||||
|
||||
/* Give preference to /etc/passwd than HOME */
|
||||
const gchar *
|
||||
g_get_home_dir (void)
|
||||
{
|
||||
|
||||
+2
-13
@@ -74,18 +74,13 @@
|
||||
#define NO_INTR(var,cmd) do { (var) = (cmd); } while ((var) == -1 && errno == EINTR)
|
||||
#define CLOSE_PIPE(p) do { close (p [0]); close (p [1]); } while (0)
|
||||
|
||||
#if defined(__APPLE__)
|
||||
#if defined (TARGET_OSX)
|
||||
#if defined(__APPLE__) && !defined (__arm__)
|
||||
/* Apple defines this in crt_externs.h but doesn't provide that header for
|
||||
* arm-apple-darwin9. We'll manually define the symbol on Apple as it does
|
||||
* in fact exist on all implementations (so far)
|
||||
*/
|
||||
gchar ***_NSGetEnviron(void);
|
||||
gchar ***_NSGetEnviron();
|
||||
#define environ (*_NSGetEnviron())
|
||||
#else
|
||||
static char *mono_environ[1] = { NULL };
|
||||
#define environ mono_environ
|
||||
#endif /* defined (TARGET_OSX) */
|
||||
#elif defined(_MSC_VER)
|
||||
/* MS defines this in stdlib.h */
|
||||
#else
|
||||
@@ -253,9 +248,6 @@ g_spawn_command_line_sync (const gchar *command_line,
|
||||
GError **error)
|
||||
{
|
||||
#ifdef G_OS_WIN32
|
||||
#elif !defined (HAVE_FORK) || !defined (HAVE_EXECV)
|
||||
fprintf (stderr, "g_spawn_command_line_sync not supported on this platform\n");
|
||||
return FALSE;
|
||||
#else
|
||||
pid_t pid;
|
||||
gchar **argv;
|
||||
@@ -352,9 +344,6 @@ g_spawn_async_with_pipes (const gchar *working_directory,
|
||||
GError **error)
|
||||
{
|
||||
#ifdef G_OS_WIN32
|
||||
#elif !defined (HAVE_FORK) || !defined (HAVE_EXECVE)
|
||||
fprintf (stderr, "g_spawn_async_with_pipes is not supported on this platform\n");
|
||||
return FALSE;
|
||||
#else
|
||||
pid_t pid;
|
||||
int info_pipe [2];
|
||||
|
||||
@@ -219,10 +219,10 @@ g_get_charset (G_CONST_RETURN char **charset)
|
||||
is_utf8 = FALSE;
|
||||
#else
|
||||
/* These shouldn't be heap allocated */
|
||||
#if defined(HAVE_LANGINFO_H)
|
||||
my_charset = nl_langinfo (CODESET);
|
||||
#elif defined(HAVE_LOCALCHARSET_H)
|
||||
#if HAVE_LOCALCHARSET_H
|
||||
my_charset = locale_charset ();
|
||||
#elif defined(HAVE_LANGINFO_H)
|
||||
my_charset = nl_langinfo (CODESET);
|
||||
#else
|
||||
my_charset = "UTF-8";
|
||||
#endif
|
||||
|
||||
+1
Submodule external/Lucene.Net added at 88fb67b076.
Vendored
-1
Submodule external/Lucene.Net.Light deleted from 85978b7eb9.
Vendored
+1
-1
Submodule external/binary-reference-assemblies updated: fcb3074202...4abf9a74bd.
Loaded 100 of 9624 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user