03 2016 档案

摘要:from http://blog.igorminar.com/2007/03/how-java-application-can-discover-its.html Occasionally it is important for an application to know its PID, spe 阅读全文
posted @ 2016-03-30 17:20 princessd8251 阅读(199) 评论(0) 推荐(0) 编辑
摘要:ObjectHeader32.txt |----------------------------------------------------------------------------------------|--------------------| | Object Header (64 bits) ... 阅读全文
posted @ 2016-03-30 15:15 princessd8251 阅读(346) 评论(0) 推荐(0) 编辑
摘要:几天前在HLLVM群组有人问了个小问题,说 Java代码 public class Test { static Test2 t1 = new Test2(); Test2 t2 = new Test2(); public void fn() { Test2 t3 = new Test2(); } } 阅读全文
posted @ 2016-03-29 17:08 princessd8251 编辑
摘要:from http://rednaxelafx.iteye.com/blog/730461 接着前天的与昨天的帖,今天也来介绍一个HotSpot的Serviceability Agent(以下简称SA)的玩法例子。 昨天用SA把x86机器码反汇编到汇编代码,或许对多数Java程序员来说并不怎么有趣。 阅读全文
posted @ 2016-03-29 16:18 princessd8251 编辑
摘要:from http://blog.csdn.net/on_1y/article/details/24290985 对C语言中的static关键字的深入理解 在阅读一些项目源代码时,我发现很多时候,会把函数和变量声明为static,所以,很好奇为什么要这样做,于是有了下面这篇文章。 基本概念 使用st 阅读全文
posted @ 2016-03-29 00:22 princessd8251 阅读(105) 评论(0) 推荐(0) 编辑
摘要:from http://www.oracle.com/technetwork/articles/javase/jvmti-136367.html The Java Virtual Machine Tool Interface (JVMTI) provides a programming interf 阅读全文
posted @ 2016-03-28 11:25 princessd8251 阅读(424) 评论(0) 推荐(0) 编辑
摘要:from http://blog.csdn.net/on_1y/article/details/24660859 在Java多线程程序中,由于线程调度,指令间的次序在每次运行时都可能不相同,有时候,我们需要得到指令次序,用来分析程序的行为。这样细粒度的底层行为用一般方法很难完成,我们需要借助 JVM 阅读全文
posted @ 2016-03-23 23:23 princessd8251 阅读(139) 评论(0) 推荐(0) 编辑
摘要:from https://opencredo.com/lambda-memoization-in-java-8/ Memoization is a technique whereby we trade memory for execution speed. Suppose you have a fu 阅读全文
posted @ 2016-03-16 15:28 princessd8251 阅读(152) 评论(0) 推荐(0) 编辑
摘要:from https://opencredo.com/new-tricks-with-dynamic-proxies-in-java-8-part-3/ In this post, the last in the New Tricks With Dynamic Proxies series (see 阅读全文
posted @ 2016-03-16 15:21 princessd8251 阅读(172) 评论(0) 推荐(0) 编辑
摘要:from https://opencredo.com/dynamic-proxies-java-part-2/ Consider an instance of java.reflection.InvocationHandler that simply passes every method call 阅读全文
posted @ 2016-03-16 15:10 princessd8251 阅读(142) 评论(0) 推荐(0) 编辑
摘要:from https://opencredo.com/dynamic-proxies-java/ Dynamic proxies have been a feature of Java since version 1.3. They were widely used in J2EE for remo 阅读全文
posted @ 2016-03-16 15:08 princessd8251 阅读(192) 评论(0) 推荐(0) 编辑
摘要:from http://arturmkrtchyan.com/java-object-header Have you ever wondered how java object looks like inside JVM ? Today’s post will mainly target the h 阅读全文
posted @ 2016-03-15 00:49 princessd8251 阅读(724) 评论(0) 推荐(0) 编辑
摘要:from http://arturmkrtchyan.com/jvm-biased-locking In today’s article I’m going to talk about Biased Locking in jvm. In case you are not familiar with 阅读全文
posted @ 2016-03-15 00:48 princessd8251 阅读(464) 评论(0) 推荐(0) 编辑
摘要:转自 http://www.cnblogs.com/redcreen/archive/2011/03/29/1998801.html       Java偏向锁(Biased Locking)是Java6引入的一项多线程优化。它通过消除资源无竞争情况下的同步原语,进一步提高了程序的运行性能。     阅读全文
posted @ 2016-03-15 00:39 princessd8251 阅读(143) 评论(0) 推荐(0) 编辑
摘要:转自http://www.cnblogs.com/redcreen/archive/2011/03/29/1998801.html  大家知道,Java的多线程安全是基于Lock机制实现的,而Lock的性能往往不如人意。原因是,monitorenter与monitorexit这两个控制多线程同步的b 阅读全文
posted @ 2016-03-15 00:35 princessd8251 阅读(588) 评论(0) 推荐(0) 编辑
摘要:指令码 助记符    说明   0x00 nop      什么都不做   0x01 aconst_null 将null推送至栈顶   0x02 iconst_m1   将int型-1推送至栈顶   0x03 iconst_0   将int型0推送至栈顶   0x04  阅读全文
posted @ 2016-03-15 00:19 princessd8251 阅读(146) 评论(0) 推荐(0) 编辑
摘要:Stop the world pauses of JVM due to work of garbage collector are known foes of java based application. HotSpot JVM has a set of very advanced and tun 阅读全文
posted @ 2016-03-13 22:47 princessd8251 阅读(290) 评论(0) 推荐(0) 编辑
摘要:from http://coolshell.cn/articles/9606.html 在淘宝内网里看到同事发了贴说了一个CPU被100%的线上故障,并且这个事发生了很多次,原因是在Java语言在并发情况下使用HashMap造成Race Condition,从而导致死循环。这个事情我4、5年前也经历 阅读全文
posted @ 2016-03-10 18:55 princessd8251 阅读(266) 评论(0) 推荐(0) 编辑
摘要:Strongly reachable: An object that can be accessed by a strong reference. Softly reachable: An object that is not strongly reachable and can be access 阅读全文
posted @ 2016-03-10 18:51 princessd8251 阅读(168) 评论(0) 推荐(0) 编辑
摘要:from https://dzone.com/articles/letting-garbage-collector-do-c Garbage collection in Java is great, but in some cases you want to listen when an objec 阅读全文
posted @ 2016-03-10 17:51 princessd8251 阅读(114) 评论(0) 推荐(0) 编辑
摘要:from http://hongjiang.info/java-referencequeue/#comment-4236 看到了这篇帖子: 《WeakHashMap的神话》http://www.javaeye.com/topic/587995因为Javaeye回帖还要先做个论坛小测验,所以懒得在上面 阅读全文
posted @ 2016-03-10 16:52 princessd8251 阅读(138) 评论(0) 推荐(0) 编辑
摘要:from http://www.infoq.com/cn/articles/Java-Application-Hostile-to-JIT-Compilation 在JVM中,即时编译器(以下简称JIT)是很重要的一部分,可以帮助应用大幅度提升执行效率。但是很多程序却并不能很好地利用JIT的高性能优 阅读全文
posted @ 2016-03-10 14:51 princessd8251 阅读(169) 评论(0) 推荐(0) 编辑
摘要:#include <stdio.h> #include <stdlib.h> #include <stddef.h> #include <string.h> #include "jvmti.h" #include "jni.h" #pragma GCC diagnostic ignored "-Ww 阅读全文
posted @ 2016-03-09 18:50 princessd8251 阅读(920) 评论(0) 推荐(0) 编辑
摘要:Question: How to make a dump before and after a full GC? JDk already support our requirement. What we need is just enable below red flag. We have two 阅读全文
posted @ 2016-03-07 14:57 princessd8251 阅读(3807) 评论(0) 推荐(0) 编辑
摘要:import java.util.*; public class HashMapStackOverflow { public static void main(String[] args) throws Exception { HashMap<String, Object> map = new Ha 阅读全文
posted @ 2016-03-07 14:17 princessd8251 阅读(295) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示